-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add margin top/bottom to the iframe of spearkerdeck
- Loading branch information
Showing
1 changed file
with
20 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,27 +1,30 @@ | ||
'use client' | ||
|
||
import { Box } from '@chakra-ui/react' | ||
import * as React from 'react' | ||
|
||
type SpeakerDeckProps = { | ||
id: string | ||
} | ||
|
||
export const SpeakerDeck: React.FC<SpeakerDeckProps> = ({ id }) => ( | ||
<iframe | ||
className="speakerdeck-iframe" | ||
src={`https://speakerdeck.com/player/${id}`} | ||
allowFullScreen | ||
style={{ | ||
border: '0px', | ||
background: 'padding-box padding-box rgba(0, 0, 0, 0.1)', | ||
margin: '0px', | ||
padding: '0px', | ||
borderRadius: '6px', | ||
boxShadow: 'rgba(0, 0, 0, 0.2) 0px 5px 40px', | ||
width: '100%', | ||
height: 'auto', | ||
aspectRatio: '560 / 315', | ||
}} | ||
data-ratio="1.7777777777777777" | ||
/> | ||
<Box my={8}> | ||
<iframe | ||
className="speakerdeck-iframe" | ||
src={`https://speakerdeck.com/player/${id}`} | ||
allowFullScreen | ||
style={{ | ||
border: '0px', | ||
background: 'padding-box padding-box rgba(0, 0, 0, 0.1)', | ||
margin: '0px', | ||
padding: '0px', | ||
borderRadius: '6px', | ||
boxShadow: 'rgba(0, 0, 0, 0.2) 0px 5px 40px', | ||
width: '100%', | ||
height: 'auto', | ||
aspectRatio: '560 / 315', | ||
}} | ||
data-ratio="1.7777777777777777" | ||
/> | ||
</Box> | ||
) |