chore: add files from master-wiki repo
This commit is contained in:
parent
f99a9ae2ac
commit
1847f6bf28
315 changed files with 1047341 additions and 0 deletions
24
_master_wiki/03. Resources/Development/Iframes.md
Normal file
24
_master_wiki/03. Resources/Development/Iframes.md
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
---
|
||||
created: 2024-02-20 11:43
|
||||
updated: 2024-03-12 13:49
|
||||
---
|
||||
|
||||
## How to make an Iframe 100% it's parent width while maintaining the aspect ratio
|
||||
|
||||
In this example, we need to wrap the iframe in a container class and provide the following styles:
|
||||
|
||||
```css
|
||||
.container {
|
||||
position: relative;
|
||||
width: 100%;
|
||||
height: 0;
|
||||
padding-bottom: 56.25%;
|
||||
}
|
||||
iframe {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
```
|
||||
Loading…
Add table
Add a link
Reference in a new issue