1.5.2-css

作业2css:

.bg {
  background: url('images/brick.jpg');
  background-size: 75px 75px;
  background-repeat: repeat;
  height: 384px;

}

.cobble {
  background: url('images/cobble_stone.png');
  background-size: 60px 60px;
  background-repeat: repeat;
  width: 256px;
  height: 192px;
  position: absolute;
  left: 50%;
  transform: translate(-50%);

}

.stonebrick {
  background: url('images/stonebrick.png');
  background-size: 64px 64px;
  background-repeat: repeat;
  width: 256px;
  height: 192px;
  position: absolute;
  left: 50%;
  top:200px;
  transform: translate(-50%);

}

.inner_cobble {
  background: url('images/inner_cobble_stone.png');
  background-size: 64px 64px;
  background-repeat: repeat;
  width: 128px;
  height: 128px;
  position: absolute;
  left: 50%;
  top:64px;
  transform: translate(-50%);

}

.bars {
  background: url('images/Iron_bars.png');
  background-size: 64px 64px;
  background-repeat: repeat-x;
  width: 128px;
  height: 64px;
  position: absolute;
  left: 50%;
  top:64px;
  transform: translate(-50%);

}

.fire {
  background: url('images/har.gif');
  background-size: 128px 128px;

  width: 128px;
  height: 128px;
  position: absolute;
  left: 50%;
  top:64px;
  transform: translate(-50%);

}

最后编辑于
©著作权归作者所有,转载或内容合作请联系作者
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

推荐阅读更多精彩内容