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

update docs landing page #5974

Merged
merged 17 commits into from
May 9, 2024
143 changes: 88 additions & 55 deletions src/data/indexData.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,70 +20,81 @@ export const ProductLinkData = {
title: 'Grow as your app evolves',
icon: 'triangle',
description:
'Expand your application capabilities with global database caching, connection pooling and real-time database events.',
'Expand your application capabilities with global database caching, connection pooling, and real-time database subscriptions.',
links: [
{
url: '/accelerate',
url: '/accelerate/what-is-accelerate',
title: 'Prisma Accelerate',
},
{
url: '/pulse',
url: '/pulse/what-is-pulse',
title: 'Prisma Pulse',
},
],
},
}

export const ORMCardLinkData = {
components: [
{
url: '/orm/prisma-schema',
title: 'Prisma Schema',
},
{
url: '/orm/tools/prisma-cli',
title: 'Prisma CLI',
},
{
url: '/orm/prisma-client',
title: 'Prisma Client',
},
{
url: '/orm/tools/prisma-studio',
title: 'Prisma Studio',
},
{
url: '/orm/prisma-migrate',
title: 'Prisma Migrate',
},
],
reference: [
{
url: '/orm/reference/prisma-client-reference',
title: 'Prisma Client API reference',
},
{
url: '/orm/reference/prisma-schema-reference',
title: 'Prisma schema reference',
},
{
url: '/orm/reference/error-reference',
title: 'Error message reference',
},
{
url: '/orm/reference/prisma-cli-reference',
title: 'Prisma CLI reference',
},
],
components: {
title: 'ORM Components',
description: 'Learn about the building blocks of Prisma ORM.',
links: [
{
url: '/orm/prisma-schema',
title: 'Prisma Schema',
},
{
url: '/orm/tools/prisma-cli',
title: 'Prisma CLI',
},
{
url: '/orm/prisma-client',
title: 'Prisma Client',
},
{
url: '/orm/tools/prisma-studio',
title: 'Prisma Studio',
},
{
url: '/orm/prisma-migrate',
title: 'Prisma Migrate',
},
],
},

reference: {
title: 'Reference',
meletj marked this conversation as resolved.
Show resolved Hide resolved
description: 'Understand the capabilities and usage of our products.',
meletj marked this conversation as resolved.
Show resolved Hide resolved
links: [
{
url: '/orm/reference/prisma-client-reference',
title: 'Client API reference',
meletj marked this conversation as resolved.
Show resolved Hide resolved
},
{
url: '/orm/reference/prisma-schema-reference',
title: 'Schema reference',
},
{
url: '/orm/reference/error-reference',
title: 'Error message reference',
},
{
url: '/orm/reference/prisma-cli-reference',
title: 'Prisma CLI reference',
},
{
url: '/accelerate/api-reference',
title: 'Accelerate API',
},
{
url: '/pulse/api-reference',
title: 'Pulse API',
},
],
}
}

export const ORMGeneralLinkData = [
{
title: `What is Prisma ORM`,
description: 'An overview of what Prisma ORM is and how it works.',
url: '/orm/overview/introduction/what-is-prisma',
icon: 'fa-regular fa-question',
},
{
title: `CRUD`,
description: 'How to perform CRUD operations with your generated Prisma Client API. ',
Expand All @@ -97,12 +108,6 @@ export const ORMGeneralLinkData = [
url: '/orm/overview/prisma-in-your-stack',
icon: 'fa-solid fa-server',
},
{
title: `Preview features`,
description: 'Available preview features and how to enable them.',
url: '/orm/reference/preview-features',
icon: 'fa-solid fa-eye',
},
{
title: `Adopting Prisma ORM`,
description: 'Migrate to Prisma ORM from other ORMs.',
Expand All @@ -116,6 +121,34 @@ export const ORMGeneralLinkData = [
url: '/orm/prisma-client/deployment',
icon: 'fa-solid fa-book',
},
{
meletj marked this conversation as resolved.
Show resolved Hide resolved
title: `Accelerate`,
description:
'Set up connection pooling and global cache in your app with Accelerate.',
meletj marked this conversation as resolved.
Show resolved Hide resolved
url: '/accelerate/getting-started',
icon: 'fa-solid fa-bolt',
},
{
title: `Pulse`,
description:
'React to changes in your database with Pulse.',
url: '/pulse/getting-started',
icon: 'fa-solid fa-signal-stream',
},
{
title: `Console`,
meletj marked this conversation as resolved.
Show resolved Hide resolved
description:
'Explore how use our Console to efficiently collaborate with your team on the Prisma Data Platform.',
meletj marked this conversation as resolved.
Show resolved Hide resolved
url: '/platform/concepts',
icon: 'fa-solid fa-chart-simple',
},
{
title: `Platform CLI commands`,
description:
'Learn how to access the Prisma Data Platform using the integrated commands in the Prisma CLI.',
meletj marked this conversation as resolved.
Show resolved Hide resolved
url: '/platform/platform-cli/commands',
icon: 'fa-solid fa-terminal',
},
]

export const DatabaseData = [
Expand Down
13 changes: 10 additions & 3 deletions src/pages/index.module.scss
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@
display: inline-flex;
align-items: center;
justify-content: center;
color: var(--icon-svg-color);
color: #2D3748;
}

.h3 {
Expand Down Expand Up @@ -87,9 +87,10 @@
'Helvetica Neue', Arial, 'Noto Sans', sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji',
'Segoe UI Symbol', 'Noto Color Emoji';
font-weight: normal;
font-size: 18px;
font-size: 16px;
letter-spacing: 0em;
line-height: 140%;
color: var(--secondary-font-color);
}

.homepageTopSection {
Expand Down Expand Up @@ -258,7 +259,7 @@
}

.icon {
background: var(--icon-wrapper-bg);
background: #F7FAFC;
}

&:hover {
Expand Down Expand Up @@ -298,10 +299,16 @@
line-height: 140%;
/* 22.4px */
}

a,
button {
color: var(--link-color);
}
}

.linkGrid {
gap: 12px;
max-width: 599px;

a {
min-width: calc(50% - 8px);
Expand Down
24 changes: 11 additions & 13 deletions src/pages/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ function HomepageORMLinksSection() {
return (
<div className={styles.ormLinkSectionWrapper}>
<Heading as="h4" className={styles.h4}>
Prisma ORM
Resources
</Heading>
<div>
{ORMGeneralLinkData.map((link, index) => (
Expand Down Expand Up @@ -102,24 +102,21 @@ function HomepageORMCards() {
{Object.keys(ORMCardLinkData).map((e) => {
const cardHeader = (
<Heading as="h4" className={styles.h4}>
{e[0].toUpperCase() + e.substring(1).toLowerCase()}
{ORMCardLinkData[e].title}
</Heading>
);
const cardBody = (
<p>
Open source Node.js and TypeScript ORM with an intuitive data model, automated
migrations, type-safety, and auto-completion.
</p>
);
const links = ORMCardLinkData[e].map((card) => (
<Link to={card.url}>{card.title} &#8594;</Link>
const cardBody = <div className={styles.body}>{ORMCardLinkData[e].description}</div>;
const cardLinks = ORMCardLinkData[e].links.map((link) => (
<Link to={link.url}>
{link.title} {link.external ? <>&#8599;</> : <>&#8594;</>}
</Link>
));
return (
<HomepageCard
className={styles.productCardIndigo}
heading={cardHeader}
body={cardBody}
links={links}
links={cardLinks}
/>
);
})}
Expand All @@ -135,9 +132,10 @@ function HomepageDatabasesSection() {
Databases
</Heading>
<div className={styles.body}>
Prisma ORM works seamlessly across most popular databases and service providers. <br />
Prisma ORM works seamlessly across most popular databases and service providers.
Refer to our <Link to="/orm/reference/database-features">Database features matrix</Link> for information about supported features and types for
each database.
each database.<br />
Explore what databases and database providers <Link to="/accelerate/getting-started#prerequisites">Accelerate</Link> and <Link to="https://www.prisma.io/docs/pulse/database-setup">Pulse</Link> support.
meletj marked this conversation as resolved.
Show resolved Hide resolved
</div>
<div className={styles.databaseGrid}>
{DatabaseData.map((e) => (
Expand Down
Loading