Skip to content

Commit 1a3422c

Browse files
docs updates
1 parent e961613 commit 1a3422c

File tree

2 files changed

+23
-2
lines changed

2 files changed

+23
-2
lines changed

docs/src/components/YouTubePreview/YouTubePreview.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ export function YouTubePreview ({url}: YouTubePreviewProps) {
3434
className="youtube-preview-link"
3535
>
3636
<img
37-
src={`https://img.youtube.com/vi/${videoId}/hqdefault.jpg`}
37+
src={`https://img.youtube.com/vi/${videoId}/maxresdefault.jpg`}
3838
alt="Watch on YouTube"
3939
className="youtube-preview-img"
4040
/>

docs/src/components/YouTubePreview/style.css

Lines changed: 22 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,16 +2,19 @@
22
display: flex;
33
justify-content: center;
44
margin: 2rem 0;
5+
padding: 0 1rem;
56
}
67

78
.youtube-preview-link {
89
position: relative;
910
display: inline-block;
11+
max-width: 100%;
1012
}
1113

1214
.youtube-preview-img {
1315
width: 720px;
14-
height: 405px;
16+
max-width: 100%;
17+
height: auto;
1518
cursor: pointer;
1619
border-radius: 8px;
1720
display: block;
@@ -27,4 +30,22 @@
2730
display: flex;
2831
align-items: center;
2932
justify-content: center;
33+
}
34+
35+
@media screen and (max-width: 768px) {
36+
.youtube-preview-container {
37+
margin: 1rem 0;
38+
}
39+
40+
.youtube-preview-play svg {
41+
width: 48px;
42+
height: 34px;
43+
}
44+
}
45+
46+
@media screen and (max-width: 480px) {
47+
.youtube-preview-play svg {
48+
width: 40px;
49+
height: 28px;
50+
}
3051
}

0 commit comments

Comments
 (0)