Skip to content

Commit 57d3fec

Browse files
committed
Spruce up introduction steps with component
1 parent f6555f1 commit 57d3fec

File tree

4 files changed

+100
-3
lines changed

4 files changed

+100
-3
lines changed

docs/index.mdx

+18-3
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,24 @@ Be sure to check us out on [GitHub](https://github.com/velopack/velopack) and [j
66

77
## Overview
88
To enable your application to make full use of Velopack, you need to do 3 things:
9-
1. Integrate the SDK into your app, and check for updates. [[Read more]](integrating/overview.mdx)
10-
0. Run the `vpk` command line tool to generate your update packages and installers. [[Read more]](packaging/overview.mdx)
11-
0. Upload your release somewhere your app can download updates from. [[Read more]](distributing/overview.mdx)
9+
10+
<FancyStep step={1}>
11+
### Integrate the SDK & check for updates.
12+
We have client libraries for some [languages below](#language-support), or if we don't support your language yet you can use [our CLI](./getting-started/fusion-cli.mdx). <br/>
13+
[Read more →](integrating/overview.mdx)
14+
</FancyStep>
15+
16+
<FancyStep step={2}>
17+
### Build a Velopack release
18+
Our command-line tool `vpk` can help you build update packages and installers in just one command. <br/>
19+
[Read more →](packaging/overview.mdx)
20+
</FancyStep>
21+
22+
<FancyStep step={3} noline>
23+
### Upload your releases somewhere
24+
You can host updates anywhere static files can be served, eg. cloud file storage, GitHub Releases, and more. <br/>
25+
[Read more →](distributing/overview.mdx)
26+
</FancyStep>
1227

1328
## Language Support
1429
There are libraries planned or supported for the languages below.

src/components/FancyStep.tsx

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
import "../css/FancyStep.css";
2+
import type { PropsWithChildren } from 'react';
3+
import MDXContent from '@theme/MDXContent';
4+
5+
export type FancyStepProps = PropsWithChildren & {
6+
step: number;
7+
noline: boolean;
8+
};
9+
10+
export default function FancyStep({ step, noline, children }: FancyStepProps) {
11+
return (
12+
<div className="fancystep-root">
13+
<div className={noline ? "" : "fancystep-leftcol"}>
14+
<div className="fancystep-number">{step}</div>
15+
</div>
16+
<div className="fancystep-content">
17+
<MDXContent>{children}</MDXContent>
18+
</div>
19+
</div>
20+
);
21+
}

src/css/FancyStep.css

+59
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
.fancystep-root {
2+
flex-direction: row;
3+
flex-wrap: nowrap;
4+
display: flex;
5+
gap: 20px;
6+
margin-top: 20px;
7+
margin-left: 6px;
8+
}
9+
10+
.fancystep-number {
11+
width: 40px;
12+
height: 40px;
13+
text-align: center;
14+
line-height: 38px;
15+
border-radius: 999px;
16+
background-color: var(--ifm-color-primary-light);
17+
position: relative;
18+
color: rgba(255, 255, 255, 0.9);
19+
font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
20+
font-size: var(--ifm-h3-font-size);
21+
font-weight: bold;
22+
}
23+
24+
[data-theme='dark'] .fancystep-number {
25+
color: black;
26+
}
27+
28+
.fancystep-leftcol {
29+
position: relative;
30+
}
31+
32+
.fancystep-leftcol::after {
33+
content: '';
34+
background-color: var(--ifm-color-primary-light);
35+
position: absolute;
36+
left: 20px;
37+
opacity: 0.5;
38+
top: 60px;
39+
right: 19px;
40+
bottom: 0px;
41+
}
42+
43+
.fancystep-number::before {
44+
content: '';
45+
position: absolute;
46+
left: -6px;
47+
right: -6px;
48+
top: -6px;
49+
bottom: -6px;
50+
opacity: 0.3;
51+
z-index: -1;
52+
border-radius: 999px;
53+
background-color: var(--ifm-color-primary-light);
54+
}
55+
56+
.fancystep-content {
57+
flex: 1;
58+
padding-top: 6px;
59+
}

src/theme/MDXComponents.js

+2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
import MDXComponents from '@theme-original/MDXComponents';
22
import AppliesTo from '@site/src/components/AppliesTo';
3+
import FancyStep from '@site/src/components/FancyStep';
34

45
export default {
56
...MDXComponents,
67
AppliesTo,
8+
FancyStep,
79
};

0 commit comments

Comments
 (0)