Skip to content

Commit 8c3f7f6

Browse files
committed
Add install buttons with links to selector tool
1 parent 7e3d722 commit 8c3f7f6

File tree

2 files changed

+42
-35
lines changed

2 files changed

+42
-35
lines changed

site/src/components/Installation/installation.tsx

Lines changed: 26 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,51 +1,63 @@
1+
import Link from '@docusaurus/Link';
12
import styles from './styles.module.css';
23

3-
import Link from '@docusaurus/Link';
4+
import Button from '@site/src/components/Button';
45
import LinuxLogo from '@site/static/img/linux-logo.svg';
56
import MacOSLogo from '@site/static/img/mac-os-logo.svg';
67
import WindowsLogo from '@site/static/img/windows-logo.svg';
78
import Heading from '@theme/Heading';
89

10+
const getInstallLink = (os: 'WINDOWS' | 'MACOS' | 'LINUX') =>
11+
`https://docs.openvino.ai/2025/get-started/install-openvino.html?PACKAGE=OPENVINO_GENAI&VERSION=v_2025_0_0&OP_SYSTEM=${os}&DISTRIBUTION=PIP`;
12+
913
const INSTALLATION_ITEMS = [
1014
{
11-
title: 'Linux install',
15+
title: 'Linux',
1216
Icon: LinuxLogo,
17+
link: getInstallLink('LINUX'),
1318
},
1419
{
15-
title: 'Windows install',
20+
title: 'Windows',
1621
Icon: WindowsLogo,
22+
link: getInstallLink('WINDOWS'),
1723
},
1824
{
19-
title: 'MacOS install',
25+
title: 'MacOS',
2026
Icon: MacOSLogo,
27+
link: getInstallLink('MACOS'),
2128
},
2229
];
2330

24-
const InstallationItems = () => {
31+
const InstallationOptions = () => {
2532
return (
26-
<ul className={styles.installationOptions}>
27-
{INSTALLATION_ITEMS.map(({ title, Icon }) => (
28-
<li key={title} className={styles.installationOptionsItem}>
29-
<Icon role="img" aria-label={title} />
30-
<span>{title}</span>
31-
</li>
33+
<div className={styles.installationOptions}>
34+
{INSTALLATION_ITEMS.map(({ title, Icon, link }) => (
35+
<Button
36+
key={title}
37+
label={title}
38+
Icon={Icon}
39+
link={link}
40+
size="lg"
41+
outline
42+
variant="secondary"
43+
/>
3244
))}
33-
</ul>
45+
</div>
3446
);
3547
};
3648

3749
export const Installation = () => {
3850
return (
3951
<section className={styles.installation}>
40-
<Heading as="h4" className={styles.installationTitle}>
52+
<Heading as="h2" className={styles.installationTitle}>
4153
Install OpenVINO™ GenAI
4254
</Heading>
4355
<p className={styles.installationDescription}>
4456
Unlock the power of OpenVINO GenAI™ for your projects. <br />
4557
Get started with seamless installation now!
4658
</p>
4759

48-
<InstallationItems />
60+
<InstallationOptions />
4961

5062
<p>
5163
Full list of installation options <Link href="docs/overview/installation">here</Link>
Lines changed: 16 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,9 @@
11
.installation {
2-
background: none;
32
text-align: center;
43
display: flex;
54
flex-direction: column;
65
justify-content: center;
7-
gap: 24px;
8-
}
9-
10-
.installationOptions {
11-
display: flex;
12-
justify-content: center;
13-
align-items: center;
14-
gap: 24px;
15-
}
16-
17-
.installationOptionsItem {
18-
display: flex;
19-
align-items: center;
20-
justify-content: center;
21-
border: 1px solid #e9e9e9;
22-
font-weight: 500;
23-
height: 64px;
24-
width: 280px;
25-
gap: 16px;
6+
gap: 1.5rem;
267
}
278

289
.installationTitle {
@@ -34,5 +15,19 @@
3415

3516
.installationDescription {
3617
margin: 0 auto;
37-
text-align: center;
18+
}
19+
20+
.installationOptions {
21+
display: flex;
22+
justify-content: center;
23+
align-items: center;
24+
gap: 1.5rem;
25+
26+
button {
27+
--button-icon-size: 2.25rem;
28+
29+
width: 14rem;
30+
height: 4rem;
31+
font-size: 1rem;
32+
}
3833
}

0 commit comments

Comments
 (0)