2
0

_comments-controls.scss 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113
  1. .comments-controls {
  2. position: relative;
  3. display: flex;
  4. justify-content: flex-end;
  5. padding-right: 2px;
  6. height: 42px;
  7. box-sizing: border-box;
  8. @include media-breakpoint-up(sm) {
  9. padding-right: 30px;
  10. height: 43px;
  11. }
  12. }
  13. .comments-toggle {
  14. $root: &;
  15. float: none;
  16. position: relative;
  17. cursor: pointer;
  18. display: flex;
  19. width: auto;
  20. align-items: center;
  21. // Wagtail adds some top padding to labels on mobile
  22. padding: 0;
  23. &--active,
  24. &:hover {
  25. #{$root}__label {
  26. opacity: 1;
  27. }
  28. #{$root}__icon {
  29. color: $color-white;
  30. }
  31. }
  32. &__icon {
  33. position: absolute;
  34. left: -12px;
  35. bottom: 3px;
  36. width: 52px;
  37. height: 52px;
  38. color: $color-teal-dark;
  39. transition: color 100ms cubic-bezier(0.4, 0, 0.2, 1);
  40. }
  41. &__count {
  42. position: absolute;
  43. top: -1px;
  44. right: -8px;
  45. width: 19px;
  46. height: 19px;
  47. box-sizing: border-box;
  48. border-radius: 50%;
  49. background-color: $color-salmon;
  50. border: 1px solid $color-teal;
  51. color: $color-white;
  52. font-size: 9px;
  53. font-weight: 700;
  54. text-align: center;
  55. line-height: 17px;
  56. &:empty {
  57. display: none;
  58. }
  59. }
  60. &__icon-wrapper {
  61. width: 28px;
  62. height: 52px;
  63. position: relative;
  64. }
  65. &__label {
  66. font-size: 12px;
  67. text-transform: uppercase;
  68. color: $color-white;
  69. font-weight: 400;
  70. margin-right: 10px;
  71. opacity: 0;
  72. pointer-events: none;
  73. transition: opacity 100ms cubic-bezier(0.4, 0, 0.2, 1);
  74. }
  75. [type=checkbox] {
  76. position: absolute;
  77. opacity: 0;
  78. pointer-events: none;
  79. top: -20px;
  80. }
  81. [type=checkbox]:checked + &__icon {
  82. opacity: 1;
  83. }
  84. }
  85. .comment-notifications-toggle {
  86. label {
  87. padding: 0;
  88. margin: 0;
  89. padding-top: 5px;
  90. font-weight: normal;
  91. font-size: 13px;
  92. color: $color-white;
  93. display: flex;
  94. justify-content: space-between;
  95. }
  96. .switch__toggle {
  97. margin-left: 15px;
  98. }
  99. }