GrowiSubNavigation.module.scss 3.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199
  1. @use '~/styles/variables' as var;
  2. @use '~/styles/bootstrap/init' as bs;
  3. @use '~/styles/mixins';
  4. // https://github.com/css-modules/css-modules/issues/295#issuecomment-404873976
  5. // workaround to use '&' in global scope
  6. .grw-subnav {
  7. :global {
  8. min-height: var.$grw-subnav-min-height;
  9. padding-top: 8px;
  10. padding-bottom: 8px;
  11. @include bs.media-breakpoint-up(md) {
  12. min-height: var.$grw-subnav-min-height-md;
  13. }
  14. .grw-drawer-toggler {
  15. width: 50px;
  16. height: 50px;
  17. font-size: 24px;
  18. }
  19. h1 {
  20. @include mixins.variable-font-size(32px);
  21. line-height: 1.4em;
  22. }
  23. .grw-taglabels-container {
  24. margin-bottom: 0.5rem;
  25. }
  26. .grw-page-path-nav {
  27. .separator {
  28. margin-right: 0.2em;
  29. margin-left: 0.2em;
  30. }
  31. }
  32. .btn-subscribe {
  33. height: 40px;
  34. font-size: 20px;
  35. }
  36. .btn-like,
  37. .btn-bookmark,
  38. .btn-seen-user {
  39. height: 40px;
  40. padding-right: 6px;
  41. padding-left: 8px;
  42. font-size: 20px;
  43. svg {
  44. width: 20px;
  45. height: 20px;
  46. }
  47. }
  48. .total-likes,
  49. .total-bookmarks {
  50. display: flex;
  51. align-items: flex-end;
  52. padding-right: 8px;
  53. padding-left: 6px;
  54. font-size: 14px;
  55. font-weight: bs.$font-weight-bold;
  56. }
  57. .seen-user-count {
  58. padding-right: 6px;
  59. padding-left: 6px;
  60. font-size: 14px;
  61. font-weight: bs.$font-weight-bold;
  62. vertical-align: bottom;
  63. }
  64. .btn-page-item-control {
  65. height: 40px;
  66. font-size: 16px;
  67. }
  68. ul.authors {
  69. li {
  70. font-size: 12px;
  71. list-style: none;
  72. }
  73. .text-date {
  74. font-size: 11px;
  75. }
  76. .picture {
  77. width: 22px;
  78. height: 22px;
  79. border: 1px solid bs.$gray-300;
  80. &.picture-xs {
  81. width: 14px;
  82. height: 14px;
  83. }
  84. }
  85. .user-list-popover {
  86. max-width: 200px;
  87. .user-list-content {
  88. direction: rtl;
  89. .liker-user-count,
  90. .seen-user-count {
  91. font-size: 12px;
  92. font-weight: bolder;
  93. }
  94. }
  95. .cls-1 {
  96. isolation: isolate;
  97. }
  98. }
  99. }
  100. }
  101. &:global {
  102. &:hover {
  103. .btn-copy,
  104. .btn-edit,
  105. .btn-edit-tags {
  106. // change button opacity
  107. opacity: unset;
  108. }
  109. }
  110. /*
  111. * Compact Mode
  112. */
  113. &.grw-subnav-compact {
  114. min-height: 70px;
  115. @include bs.media-breakpoint-up(md) {
  116. min-height: 90px;
  117. }
  118. .btn-like,
  119. .btn-bookmark,
  120. .btn-subscribe {
  121. width: 32px;
  122. height: 32px;
  123. padding: 4px;
  124. font-size: 16px;
  125. }
  126. .btn-seen-user {
  127. width: 48px;
  128. height: 32px;
  129. padding: 4px;
  130. font-size: 16px;
  131. svg {
  132. width: 16px;
  133. height: 16px;
  134. }
  135. }
  136. .btn-page-item-control {
  137. width: 32px;
  138. height: 32px;
  139. font-size: 12px;
  140. }
  141. }
  142. }
  143. }
  144. /*
  145. * shadow
  146. */
  147. .grw-subnav-append-shadow-container {
  148. .grw-subnav {
  149. box-shadow: 0px 0px 6px 3px rgba(black, 0.15);
  150. }
  151. }
  152. /*
  153. * Fixed ver
  154. */
  155. $easeInOutCubic: cubic-bezier(0.65, 0, 0.35, 1);
  156. .grw-subnav-fixed-container {
  157. top: var.$grw-navbar-border-width;
  158. z-index: bs.$zindex-sticky - 5;
  159. }
  160. /*
  161. * Switching show/hide
  162. */
  163. .grw-subnav-switcher {
  164. .grw-subnav-fixed-container {
  165. transition: transform 150ms $easeInOutCubic;
  166. }
  167. &.grw-subnav-switcher-hidden {
  168. .grw-subnav-fixed-container {
  169. transition: unset;
  170. transform: translateY(-100%);
  171. }
  172. }
  173. }