back-to-top.styl 635 B

123456789101112131415161718192021222324252627282930313233343536
  1. .back-to-top {
  2. background: $b2t-bg-color;
  3. bottom: $b2t-position-bottom;
  4. box-sizing: border-box;
  5. color: $b2t-color;
  6. cursor: pointer;
  7. left: $b2t-position-right;
  8. opacity: $b2t-opacity;
  9. padding: 0 6px;
  10. position: fixed;
  11. transition-property: bottom;
  12. z-index: $zindex-3;
  13. if (hexo-config('back2top.scrollpercent')) {
  14. width: initial;
  15. } else {
  16. width: 24px;
  17. span {
  18. display: none;
  19. }
  20. }
  21. &:hover {
  22. color: $sidebar-highlight;
  23. }
  24. &.back-to-top-on {
  25. bottom: $b2t-position-bottom-on;
  26. }
  27. +tablet-mobile() {
  28. left: $b2t-position-right-mobile;
  29. opacity: $b2t-opacity-hover;
  30. }
  31. }