_notifications.scss 4.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248
  1. // NOTIFICATIONS
  2. // -----------------------------------------------------------------------------
  3. /* Notifications */
  4. .notifications {
  5. display: inline-block;
  6. list-style: none;
  7. margin: 4px -10px 0 0;
  8. padding: 0;
  9. vertical-align: middle;
  10. & > li {
  11. float: left;
  12. margin: 0 10px 0 0;
  13. position: relative;
  14. .notification-icon {
  15. background: #FFF;
  16. border-radius: 50%;
  17. box-shadow: 0 2px 2px 0 rgba(0, 0, 0, 0.3);
  18. display: inline-block;
  19. height: 30px;
  20. position: relative;
  21. width: 30px;
  22. text-align: center;
  23. i {
  24. color: #777;
  25. line-height: 30px;
  26. vertical-align: middle;
  27. &.fa-tasks {
  28. line-height: 32px;
  29. }
  30. }
  31. .badge {
  32. background: #D2312D;
  33. color: #FFF;
  34. font-size: 10px;
  35. font-weight: normal;
  36. height: 16px;
  37. padding: 3px 5px 3px 5px;
  38. position: absolute;
  39. right: -8px;
  40. top: -3px;
  41. }
  42. }
  43. & > a {
  44. border: none;
  45. display: inline-block;
  46. }
  47. }
  48. .notification-menu {
  49. border: none;
  50. box-shadow: 0 0 2px rgba(0, 0, 0, 0.3);
  51. left: auto;
  52. margin: 10px 0 0 0;
  53. padding: 0;
  54. right: -5px;
  55. width: $header-notification-menu-width;
  56. &.large {
  57. width: 325px;
  58. }
  59. .notification-title {
  60. background: $header-notification-menu-title-background;
  61. border-radius: $header-notification-menu-border-radius;
  62. color: $header-notification-menu-title-color;
  63. @include font-size($header-notification-menu-title-size);
  64. @include line-height($header-notification-menu-title-size + 4);
  65. padding: $header-notification-menu-title-padding;
  66. text-transform: uppercase;
  67. .label {
  68. @include font-size($header-notification-menu-title-size - 1);
  69. font-weight: 200;
  70. line-height: 14px;
  71. margin-left: 10px;
  72. margin-top: -2px;
  73. min-width: 35px;
  74. }
  75. .label-default {
  76. background: $header-notification-menu-label-background;
  77. color: #FFF;
  78. }
  79. }
  80. .content {
  81. padding: $header-notification-menu-padding;
  82. }
  83. hr {
  84. background: $header-notification-menu-hr-background;
  85. height: 1px;
  86. margin: $header-notification-menu-hr-margin;
  87. }
  88. .view-more {
  89. color: $header-notification-menu-view-more-color;
  90. @include font-size($header-notification-menu-view-more-size);
  91. @include line-height($header-notification-menu-view-more-size);
  92. text-transform: uppercase;
  93. }
  94. }
  95. }
  96. // NOTIFICATION MENU - PIN
  97. // -----------------------------------------------------------------------------
  98. /* notification menu - pin */
  99. .notifications .notification-menu,
  100. .notifications .notification-icon {
  101. &:before {
  102. border: {
  103. bottom: $header-notification-menu-pin-width solid $header-notification-menu-title-background;
  104. left: $header-notification-menu-pin-width solid transparent;
  105. right: $header-notification-menu-pin-width solid transparent;
  106. }
  107. content: '';
  108. height: 0;
  109. margin-right: -( $header-notification-menu-pin-width / 2);
  110. width: 0;
  111. position: absolute;
  112. pointer-events: none;
  113. }
  114. }
  115. .notifications .notification-menu:before {
  116. bottom: 100%;
  117. right: 16px;
  118. }
  119. .notifications .notification-icon:before {
  120. display: none;
  121. right: 11px;
  122. top: 35px;
  123. z-index: 9999;
  124. }
  125. // NOTIFICATION MENU - EMAILS
  126. // -----------------------------------------------------------------------------
  127. /* notification menu - emails */
  128. .notification-menu {
  129. color: $notification-menu-email-message-color;
  130. ul {
  131. list-style: none;
  132. margin: 0;
  133. padding: 0;
  134. }
  135. li {
  136. margin: 0 0 12px;
  137. &:last-child {
  138. margin-bottom: 0;
  139. }
  140. }
  141. a {
  142. display: block;
  143. text-decoration: none;
  144. }
  145. .image {
  146. float: left;
  147. margin: 0 10px 0 0;
  148. i {
  149. border-radius: 35px;
  150. height: 35px;
  151. line-height: 35px;
  152. text-align: center;
  153. width: 35px;
  154. }
  155. }
  156. .truncate {
  157. overflow: hidden;
  158. text-overflow: ellipsis;
  159. white-space: nowrap;
  160. }
  161. .title {
  162. color: $notification-menu-email-name-color;
  163. display: block;
  164. @include font-size($notification-menu-email-name-size);
  165. @include line-height($notification-menu-email-name-size + 4);
  166. padding: $notification-menu-email-name-padding;
  167. }
  168. .message {
  169. color: $notification-menu-email-message-color;
  170. display: block;
  171. @include font-size($notification-menu-email-message-size);
  172. @include line-height($notification-menu-email-message-size + 4);
  173. padding: $notification-menu-email-message-padding;
  174. }
  175. }
  176. // HEADER DARK AND DARK VERSION
  177. // -----------------------------------------------------------------------------
  178. html.dark,
  179. html.header-dark {
  180. .notifications {
  181. > li .notification-icon {
  182. background: lighten( $sidebar-background, 5% );
  183. i {
  184. color: $page-header-color;
  185. }
  186. }
  187. }
  188. }
  189. // NOTIFICATIONS
  190. // -----------------------------------------------------------------------------
  191. /* Notifications Mobile */
  192. @media only screen and (max-width: 767px) {
  193. .notifications {
  194. float: right;
  195. margin: 16px 8px 0 0;
  196. > li {
  197. position: static;
  198. &.open {
  199. .notification-icon:before {
  200. display: block;
  201. }
  202. }
  203. .notification-menu {
  204. left: 15px;
  205. right: 15px;
  206. top: auto;
  207. width: auto !important;
  208. &:before {
  209. display: none;
  210. }
  211. }
  212. }
  213. }
  214. }