Skip to content

Commit 35c3dbd

Browse files
authored
docs: add labs lowdown videos and small material animation to thumbnails (#1288)
* docs: add labs lowdown videos and small material animation to thumbnails * update screenshot test * add card backgrounds * remove extraneous description stuff on videos * add durations * update screenshot golden
1 parent 60c0e12 commit 35c3dbd

20 files changed

+109
-17
lines changed

packages/lit-dev-content/site/_data/videos.js

Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,60 +25,126 @@ const loadVideoData = () =>
2525
summary: `Justin covers what Web Components are and how LitElement and lit-html add value on top of the native APIs. This talk covers the fundamentals of how and why Lit is architected the way it is.`,
2626
youtubeId: '9FB0GSOAESo',
2727
date: 'Jun 22 2019',
28+
duration: '50',
2829
},
2930
{
3031
title: 'Chat with Lit #1 – Westbrook Johnson (Adobe)',
3132
summary: `Listen in on this live-recorded Twitter Space episode, hosted by Rody Davis (@rodydavis) and Elliott Marquez (@techytacos), with guest Westbrook Johnson (@WestbrookJ) from Adobe.`,
3233
youtubeId: 'it-NXhxkOJo',
3334
date: 'Jul 23 2021',
35+
duration: '24',
3436
},
3537
{
3638
title: 'Lit 2.0 Release Livestream',
3739
summary: `Lit 2.0 has officially landed! Here we talk about Lit 2.0, what we've been doing, what it means to Google, and what's new. Stay tuned for a panel discussion with Lit users in the industry!`,
3840
youtubeId: 'nfb779XIhsU',
3941
date: 'Sep 21 2021',
42+
duration: '98',
4043
},
4144
{
4245
title: 'How to build your first Lit component',
4346
summary: `Learn how to build your first Lit component and use it with React, Vue, and in a markdown editor.`,
4447
youtubeId: 'QBa1_QQnRcs',
4548
date: 'Apr 25 2022',
49+
duration: '12',
4650
},
4751
{
4852
title: 'What are elements?',
4953
summary: `Software Engineer Elliott Marquez shares what elements are, how to make, and interact with them. Learn about the basic building block of the web in this video!`,
5054
youtubeId: 'x_mixcGEia4',
5155
date: 'Apr 27 2022',
56+
duration: '9',
5257
},
5358
{
5459
title: 'How to build a carousel in Lit',
5560
summary: `In this video, we build a simple-carousel using Lit, letting us explore passing children into your web component, and web component composition.`,
5661
youtubeId: '2RftvylEtrE',
5762
date: 'May 3 2022',
63+
duration: '15',
5864
},
5965
{
6066
title: 'Event communication between web components',
6167
summary: `Follow along as Lit Software Engineer Elliott Marquez shares the pros, cons, and use cases of communicating with events.`,
6268
youtubeId: 'T9mxtnoy9Qw',
6369
date: 'May 5 2022',
70+
duration: '10',
6471
},
6572
{
6673
title: 'How to style your Lit elements',
6774
summary: `We cover how the Shadow DOM works, illustrate the benefits of encapsulated CSS, and show you how to use CSS inheritance, custom properties and shadow parts to expose a flexible public styling API.`,
6875
youtubeId: 'Xt7blcyuw5s',
6976
date: 'Oct 3 2022',
77+
duration: '15',
7078
},
7179
{
7280
title: 'Introduction to Lit',
7381
summary: `Learn all about the Lit library in this beginner-friendly Lit University episode! We will cover all of the essentials, including custom elements, declarative templates, scoped styles, and reactive properties.`,
7482
youtubeId: 'uzFakwHaSmw',
7583
date: 'Nov 2 2022',
84+
duration: '13',
7685
},
7786
{
7887
title: 'Lit 3.0 Launch Event',
7988
summary: `Join the Lit team to hear all about the Lit 3.0 release and what's new in the Lit ecosystem!`,
8089
youtubeId: 'ri9FEl_hRTc',
8190
date: 'Oct 10 2023',
91+
duration: '90',
92+
},
93+
{
94+
title: 'Lit Labs: Task (graduated)',
95+
summary: `This video covers @lit-labs/task, a package under development in Lit Labs. Watch for an overview, demos, package status and more!`,
96+
youtubeId: 'niWKuGhyE0M',
97+
date: 'Jan 19 2023',
98+
duration: '9',
99+
},
100+
{
101+
title: 'Lit Labs: Context (graduated)',
102+
summary: `In this video, we cover @lit-labs/context, a package under development in Lit Labs. Watch for an overview, an explanation of the underlying Web Components Context Protocol, use cases, demos, package status and more!`,
103+
youtubeId: 'irHAr1yTE5Q',
104+
date: 'Jan 19 2023',
105+
duration: '15',
106+
},
107+
{
108+
title: 'Lit Labs: Observers',
109+
summary: `This video covers @lit-labs/observers, a package under development in Lit Labs. Watch for an overview, demos, package status and more!`,
110+
youtubeId: 'g_9PVegjQuw',
111+
date: 'Jan 19 2023',
112+
duration: '7',
113+
},
114+
{
115+
title: 'Lit Labs: SSR (server-side rendering)',
116+
summary: `This video covers @lit-labs/ssr, a server-side rendering package under development in Lit Labs. Watch for an overview, demos, project status and more!`,
117+
youtubeId: '_xcIEx2P8nk',
118+
date: 'Jan 19 2023',
119+
duration: '13',
120+
},
121+
{
122+
title: 'Lit Labs: Framework wrapper generators',
123+
summary: `This video covers framework wrapper generators, a feature of the Lit CLI under development in Lit Labs. Watch for an overview, benefits, use case, status and more!`,
124+
youtubeId: 'CL_3TLFkwNE',
125+
date: 'Jan 19 2023',
126+
duration: '13',
127+
},
128+
{
129+
title: 'Lit Labs: Motion',
130+
summary: `This video covers @lit-labs/motion, a package under development in Lit Labs. Watch for an overview, examples, quick tips, package status and more!`,
131+
youtubeId: '9jxjc-bxwfI',
132+
date: 'Jan 19 2023',
133+
duration: '17',
134+
},
135+
{
136+
title: 'Lit Labs: React (graduated)',
137+
summary: `This video covers @lit-labs/react, a package under development in Lit Labs. Watch for an overview, use cases, package status and more!`,
138+
youtubeId: 'agBn1LW6dbM',
139+
date: 'Jan 19 2023',
140+
duration: '8',
141+
},
142+
{
143+
title: 'Lit Labs: Virtualizer',
144+
summary: `This video covers @lit-labs/virtualizer, a package under development in Lit Labs. Watch for an overview, examples, features, package status and more!`,
145+
youtubeId: 'ay8ImAgO9ik',
146+
date: 'Jan 19 2023',
147+
duration: '16',
82148
},
83149
].map((videoData) => ({
84150
kind: 'video',

packages/lit-dev-content/site/css/learn-catalog.css

Lines changed: 39 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -4,17 +4,21 @@ main {
44
z-index: 0;
55
}
66

7-
#hero {
8-
--card-width: 360px;
9-
--_unit: calc(var(--card-width) / 10);
7+
:root {
8+
--learn-card-width: 360px;
9+
--_learn-unit: calc(var(--learn-card-width) / 10);
10+
--_learn-card-padding: calc(var(--_learn-unit) / 2);
11+
--_learn-card-border-radius: var(--_learn-unit);
12+
}
1013

14+
#hero {
1115
background-color: black;
1216
color: #cfcfcf;
1317
font-family: Manrope;
1418
font-weight: 200;
1519
font-size: 20px;
1620
padding: 67px 0;
17-
padding-left: calc(var(--_unit) + 40px);
21+
padding-left: calc(var(--_learn-unit) + 40px);
1822
height: 160px; /* Explicitly declared to fix layout shift as font loads */
1923
position: relative;
2024
}
@@ -95,12 +99,10 @@ md-chip-set {
9599
}
96100

97101
#chips {
98-
margin: var(--_unit);
102+
margin: var(--_learn-unit);
99103
}
100104

101105
#learn-catalog {
102-
--_unit: 36px;
103-
104106
/* Prevent a large view shift if content is empty */
105107
min-height: 400px;
106108
width: 100%;
@@ -113,8 +115,8 @@ md-chip-set {
113115

114116
.card-grid {
115117
display: grid;
116-
padding: var(--_unit);
117-
gap: var(--_unit);
118+
padding: var(--_learn-unit);
119+
gap: calc(var(--_learn-unit) / 2);
118120
grid-template-columns: minmax(360px, 1fr) minmax(360px, 1fr) minmax(360px, 1fr);
119121

120122
align-items: stretch;
@@ -127,10 +129,29 @@ md-chip-set {
127129

128130
/* Undo anchor tag typography */
129131
font-family: Manrope,sans-serif;
130-
color: #646464;
132+
color: #454545;
131133
text-decoration: none;
132134
font-weight: 400;
133135
font-size: 18px;
136+
background-color: #f4f4f4;
137+
padding: var(--_learn-card-padding);
138+
}
139+
140+
.card,
141+
.card img {
142+
transition: border-radius 0.3s cubic-bezier(0.2, 0, 1, 1);
143+
}
144+
145+
.card:hover,
146+
.card:focus,
147+
.card:active {
148+
border-radius: var(--_learn-card-border-radius);
149+
}
150+
151+
.card:hover img,
152+
.card:focus img,
153+
.card:active img {
154+
border-radius: calc(var(--_learn-card-border-radius) - var(--_learn-card-padding));
134155
}
135156

136157
.card img {
@@ -145,7 +166,8 @@ md-chip-set {
145166
margin: 10px 0 0 0;
146167
}
147168

148-
.card:hover h1 {
169+
.card:hover h1,
170+
.card:focus h1 {
149171
text-decoration: underline;
150172
}
151173

@@ -171,8 +193,8 @@ md-chip-set {
171193
}
172194

173195
/* This is the span containing the tutorial duration */
174-
.learn-kind-row span:nth-child(3) {
175-
margin-left: auto;
196+
.learn-kind-row .end {
197+
margin-inline-start: auto;
176198
}
177199

178200
#intentionally-blank {
@@ -182,14 +204,16 @@ md-chip-set {
182204

183205
@media (max-width: 1260px) {
184206
.card-grid {
185-
--card-width: 300px;
186207
grid-template-columns: repeat(2, 1fr);
187208
}
188209
}
189210

190211
@media (max-width: 690px) {
212+
:root {
213+
--learn-card-width: 300px;
214+
}
215+
191216
.card-grid {
192-
--card-width: 300px;
193217
grid-template-columns: repeat(1, 1fr);
194218
}
195219
}
19.7 KB
Loading
40.5 KB
Loading
24.9 KB
Loading
52.3 KB
Loading
24.8 KB
Loading
50.5 KB
Loading
15.9 KB
Loading
30.5 KB
Loading

0 commit comments

Comments
 (0)