<div class="container">
  <div class="box">
    <img src="https://calbum.qiniu.songxingguo.com/album/0/201912081728_%E4%B8%8A%E6%B5%B7-%E9%BB%84%E6%B5%A6_7_0/tiny" alt="">
  </div>
</div>
.container {
  width: 20px;
  height: 10px;
}
.box {
    width: 100%;
  height: 100%;
    padding1050%;
    positionrelative;
}
.box > img {
    positionabsolute;
    width100%; 
    height100%;
    left0; 
    top0;
    right:0;
    bottom:0;
}

External CSS

This Pen doesn't use any external CSS resources.

External JavaScript

This Pen doesn't use any external JavaScript resources.