image.scss 461 B

123456789101112131415161718192021222324252627282930
  1. /**
  2. * 图片相关快捷样式类
  3. *
  4. * @since 1.0.0
  5. * @version 1.0.0
  6. */
  7. .bg {
  8. backface-visibility: hidden;
  9. background-position: center center;
  10. background-repeat: no-repeat;
  11. display: inline-block;
  12. line-height: 1;
  13. &.size-cover {
  14. background-size: cover;
  15. }
  16. &.size-contain {
  17. background-size: contain;
  18. }
  19. &.position-top {
  20. background-position: center top;
  21. }
  22. &.position-bottom {
  23. background-position: center bottom;
  24. }
  25. }