Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 3 additions & 8 deletions src/components/YouTube.tsx
Original file line number Diff line number Diff line change
@@ -1,10 +1,5 @@
import React from "react"
import styled from "@emotion/styled"

const Figure = styled.figure`
display: block;
margin: 1rem 0;
`
import { Box } from "@chakra-ui/react"

/**
* @param {id} ID of the YouTube video
Expand All @@ -27,7 +22,7 @@ const YouTube: React.FC<IProps> = ({ id, start = "0", title = "YouTube" }) => {
const baseUrl = "https://www.youtube.com/embed/"
const src = baseUrl + id + startQuery
return (
<Figure>
<Box as="figure" display="block" my={4}>
<iframe
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think we'd want to refactor the iframe to Chakra. LMK if you disagree

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, thats ok 👍🏼

width="100%"
height="315"
Expand All @@ -43,7 +38,7 @@ const YouTube: React.FC<IProps> = ({ id, start = "0", title = "YouTube" }) => {
picture-in-picture"
allowFullScreen
></iframe>
</Figure>
</Box>
)
}

Expand Down