Skip to content

Commit f5e4abc

Browse files
authored
Merge pull request #368 from TypeCellOS/staging
add site videos (#367)
2 parents c81ad4e + 3d659bf commit f5e4abc

File tree

5 files changed

+77
-35
lines changed

5 files changed

+77
-35
lines changed

packages/editor/src/app/main/components/startscreen/StartScreen.module.css

Lines changed: 21 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,9 @@
2020

2121
.code_block {
2222
display: block;
23-
margin: 5em 0;
2423
}
2524

26-
.code_block img {
25+
.code_block video {
2726
box-shadow: rgb(0 0 0 / 25%) 0px 10px 30px -20px;
2827
border-radius: 20px;
2928
border: 1px solid rgba(0, 0, 0, 0.08);
@@ -71,6 +70,17 @@
7170
margin-bottom: 100px;
7271
}
7372

73+
.story > div {
74+
flex: 1 1 0px;
75+
}
76+
77+
.story video {
78+
max-width: 100%;
79+
box-shadow: rgb(0 0 0 / 25%) 0px 10px 30px -20px;
80+
border-radius: 20px;
81+
border: 1px solid rgba(0, 0, 0, 0.08);
82+
}
83+
7484
.story img {
7585
max-width: 100%;
7686
}
@@ -105,9 +115,9 @@
105115
place-self: start;
106116
text-align: left;
107117
padding: 30px;
108-
box-shadow: rgb(0 0 0 / 25%) 0px 1px 3px -2px;
109118

110119
border-radius: 20px;
120+
box-shadow: rgb(0 0 0 / 25%) 0px 1px 3px -2px;
111121
border: 1px solid rgba(0, 0, 0, 0.08);
112122
width: 100%;
113123
height: 100%;
@@ -257,6 +267,14 @@ form {
257267
.perks {
258268
grid-template-columns: repeat(1, minmax(200px, 1fr));
259269
}
270+
271+
.story {
272+
flex-direction: column;
273+
}
274+
275+
.uneven .story {
276+
flex-direction: column-reverse;
277+
}
260278
}
261279
@media (max-width: 500px) {
262280
.header,

packages/editor/src/app/main/components/startscreen/StartScreen.tsx

Lines changed: 56 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,16 @@ import { useEffect } from "react";
33
import { Link, useLocation, useNavigate } from "react-router-dom";
44
import { SessionStore } from "../../../../store/local/SessionStore";
55
// import { NotebookOverviewItem } from "../../../matrix-auth/routes/overview/NotebookOverviewItem";
6-
import { toDocs, toRegisterScreen, toTutorial } from "../../../routes/routes";
6+
import {
7+
toDocs,
8+
toLoginScreen,
9+
toRegisterScreen,
10+
toTutorial,
11+
} from "../../../routes/routes";
712
import styles from "./StartScreen.module.css";
8-
import intro from "./assets/intro.gif";
13+
import confettiVideo from "./assets/video/confetti.mp4";
14+
import savingsVideo from "./assets/video/savings.mp4";
15+
import welcomeVideo from "./assets/video/welcome.mp4";
916

1017
export const StartScreen = observer((props: { sessionStore: SessionStore }) => {
1118
const { sessionStore } = props;
@@ -49,15 +56,25 @@ export const StartScreen = observer((props: { sessionStore: SessionStore }) => {
4956
</div>
5057
<div className={styles.headerMedia}>
5158
<div className={styles.code_block}>
52-
<img src={intro} alt="TypeCell Demo" />
59+
<video autoPlay={true} loop={true} muted={true}>
60+
<source src={welcomeVideo} type="video/mp4" />
61+
Your browser does not support the video tag.
62+
</video>
5363
</div>
5464
</div>
5565
</header>
5666
<div className={styles.page + " centered"}>
5767
<section className={styles.storySection + " " + styles.uneven}>
5868
<div className={styles.content + " " + styles.story}>
5969
<div className={""}>
60-
<img src={intro} alt="TypeCell Demo" />
70+
<video
71+
autoPlay={true}
72+
loop={true}
73+
muted={true}
74+
style={{ maxWidth: "85%" }}>
75+
<source src={savingsVideo} type="video/mp4" />
76+
Your browser does not support the video tag.
77+
</video>
6178
</div>
6279
<div className={""}>
6380
<h4>Break-free from your tools with hackable software</h4>
@@ -128,7 +145,7 @@ export const StartScreen = observer((props: { sessionStore: SessionStore }) => {
128145
</section>
129146

130147
<div className={styles.section_separator} role="separator"></div>
131-
<section className={styles.storySection + " " + styles.sdf}>
148+
<section className={styles.storySection}>
132149
<div className={styles.content + " " + styles.story}>
133150
<div className={""}>
134151
<h4>Simplify the programming experience</h4>
@@ -142,7 +159,10 @@ export const StartScreen = observer((props: { sessionStore: SessionStore }) => {
142159
</p>
143160
</div>
144161
<div className={""}>
145-
<img src={intro} alt="TypeCell Demo" />
162+
<video autoPlay={true} loop={true} muted={true}>
163+
<source src={confettiVideo} type="video/mp4" />
164+
Your browser does not support the video tag.
165+
</video>
146166
</div>
147167
</div>
148168

@@ -174,29 +194,33 @@ export const StartScreen = observer((props: { sessionStore: SessionStore }) => {
174194
</section>
175195

176196
<div className={styles.section_separator} role="separator"></div>
177-
<section className={styles.storySection + " " + styles.sdf}>
197+
<section className={styles.storySection + " " + styles.uneven}>
178198
<div className={styles.content + " " + styles.story}>
179-
<div className={""}>
180-
<a
181-
href="https://discord.gg/TcJ9TRC3SV"
182-
target="_blank"
183-
rel="noreferrer">
184-
<img
185-
style={{ borderRadius: "5px" }}
186-
alt="Discord"
187-
src="https://img.shields.io/badge/Join us on discord%20-%237289DA.svg?style=for-the-badge&logo=discord&logoColor=white"
188-
/>
189-
</a>
190-
<a
191-
href="https://github.com/typecellOS/typecell"
192-
target="_blank"
193-
rel="noreferrer">
194-
<img
195-
style={{ borderRadius: "5px" }}
196-
alt="GitHub"
197-
src="https://img.shields.io/badge/Star on GitHub%20-%23eeeeee.svg?style=for-the-badge&logo=github&logoColor=black"
198-
/>
199-
</a>
199+
<div className={""} style={{ textAlign: "center" }}>
200+
<p>
201+
<a
202+
href="https://discord.gg/TcJ9TRC3SV"
203+
target="_blank"
204+
rel="noreferrer">
205+
<img
206+
style={{ borderRadius: "5px" }}
207+
alt="Discord"
208+
src="https://img.shields.io/badge/Join us on discord%20-%237289DA.svg?style=for-the-badge&logo=discord&logoColor=white"
209+
/>
210+
</a>
211+
</p>
212+
<p>
213+
<a
214+
href="https://github.com/typecellOS/typecell"
215+
target="_blank"
216+
rel="noreferrer">
217+
<img
218+
style={{ borderRadius: "5px" }}
219+
alt="GitHub"
220+
src="https://img.shields.io/badge/Star on GitHub%20-%23eeeeee.svg?style=for-the-badge&logo=github&logoColor=black"
221+
/>
222+
</a>
223+
</p>
200224
</div>
201225
<div className={""}>
202226
<h4>Join the TypeCell community</h4>
@@ -320,7 +344,7 @@ export const StartScreen = observer((props: { sessionStore: SessionStore }) => {
320344
<span>Tutorial</span>
321345
</Link>
322346
</li>
323-
<li>
347+
{/* <li>
324348
<Link to={toTutorial()}>
325349
<span>Manual</span>
326350
</Link>
@@ -329,19 +353,19 @@ export const StartScreen = observer((props: { sessionStore: SessionStore }) => {
329353
<Link to={toTutorial()}>
330354
<span>Demos</span>
331355
</Link>
332-
</li>
356+
</li> */}
333357
</ul>
334358
</div>
335359
<div className={styles.links}>
336360
<h4>Get started</h4>
337361
<ul>
338362
<li>
339-
<Link to={toTutorial()}>
363+
<Link to={toRegisterScreen()}>
340364
<span>Create account</span>
341365
</Link>
342366
</li>
343367
<li>
344-
<Link to={toDocs()}>
368+
<Link to={toLoginScreen()}>
345369
<span>Login</span>
346370
</Link>
347371
</li>
Binary file not shown.
Binary file not shown.
Binary file not shown.

0 commit comments

Comments
 (0)