_badges.scss 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. // Badges
  2. span.badge {
  3. min-width: 3rem;
  4. padding: 0 6px;
  5. margin-left: 14px;
  6. text-align: center;
  7. font-size: 1rem;
  8. line-height: $badge-height;
  9. height: $badge-height;
  10. color: color('grey', 'darken-1');
  11. float: right;
  12. box-sizing: border-box;
  13. &.new {
  14. font-weight: 300;
  15. font-size: 0.8rem;
  16. color: #fff;
  17. background-color: $badge-bg-color;
  18. border-radius: 2px;
  19. }
  20. &.new:after {
  21. content: " new";
  22. }
  23. &[data-badge-caption]::after {
  24. content: " " attr(data-badge-caption);
  25. }
  26. }
  27. // Special cases
  28. nav ul a span.badge {
  29. display: inline-block;
  30. float: none;
  31. margin-left: 4px;
  32. line-height: $badge-height;
  33. height: $badge-height;
  34. -webkit-font-smoothing: auto;
  35. }
  36. // Line height centering
  37. .collection-item span.badge {
  38. margin-top: calc(#{$collection-line-height / 2} - #{$badge-height / 2});
  39. }
  40. .collapsible span.badge {
  41. margin-left: auto;
  42. }
  43. .sidenav span.badge {
  44. margin-top: calc(#{$sidenav-line-height / 2} - #{$badge-height / 2});
  45. }
  46. table span.badge {
  47. display: inline-block;
  48. float: none;
  49. margin-left: auto;
  50. }