notification-bell.scss 4.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234
  1. .notification-bell {
  2. position: relative;
  3. display: inline-flex;
  4. &__button {
  5. position: relative;
  6. background: none;
  7. border: none;
  8. cursor: pointer;
  9. padding: 6px;
  10. font-size: 1.25rem;
  11. color: var(--text-head);
  12. border-radius: 50%;
  13. transition: background 0.15s;
  14. &:hover {
  15. outline: 1px solid var(--outline-default);
  16. background: var(--bg-icon);
  17. }
  18. }
  19. &__badge {
  20. position: absolute;
  21. top: 0;
  22. right: 0;
  23. background: var(--color-danger);
  24. color: #fff;
  25. border-radius: 50%;
  26. width: 18px;
  27. height: 18px;
  28. font-size: 0.625rem;
  29. font-weight: 700;
  30. display: flex;
  31. align-items: center;
  32. justify-content: center;
  33. pointer-events: none;
  34. }
  35. // ── Sheet(Drawer) 레이아웃 ─────────────────────────
  36. &__sheet {
  37. display: flex;
  38. flex-direction: column;
  39. padding: 0;
  40. gap: 0;
  41. border-left: 0;
  42. // SheetContent 내장 X 버튼 숨김 (커스텀 Close 사용)
  43. > button[type="button"].absolute {
  44. display: none;
  45. }
  46. }
  47. &__sheet-header {
  48. display: flex;
  49. align-items: center;
  50. justify-content: space-between;
  51. padding: 10px 16px;
  52. background: var(--bg-head);
  53. color: var(--text-normal);
  54. }
  55. &__sheet-title {
  56. font-size: 1.125rem;
  57. font-weight: 700;
  58. margin: 0;
  59. color: inherit;
  60. }
  61. &__sheet-header-right {
  62. display: flex;
  63. align-items: center;
  64. gap: 8px;
  65. }
  66. &__sheet-close {
  67. width: 32px;
  68. height: 32px;
  69. background: transparent;
  70. border: none;
  71. color: inherit;
  72. font-size: 1.25rem;
  73. cursor: pointer;
  74. &:hover {
  75. background: var(--bg-subtle);
  76. color: var(--text-primary);
  77. }
  78. }
  79. &__sheet-body {
  80. flex: 1;
  81. overflow-y: auto;
  82. min-height: 0;
  83. }
  84. &__read-all-btn {
  85. background: transparent;
  86. border: 1px solid rgba(255, 255, 255, 0.4);
  87. color: inherit;
  88. cursor: pointer;
  89. font-size: 0.75rem;
  90. font-weight: 500;
  91. padding: 4px 10px;
  92. border-radius: 4px;
  93. transition: background 0.15s;
  94. &:hover {
  95. background: rgba(255, 255, 255, 0.15);
  96. }
  97. }
  98. // ── 상태 ────────────────────────────────────────────
  99. &__loading,
  100. &__empty {
  101. padding: 24px 16px;
  102. text-align: center;
  103. color: var(--text-muted);
  104. font-size: 0.8125rem;
  105. }
  106. // ── 알림 아이템 ─────────────────────────────────────
  107. &__item {
  108. display: flex;
  109. gap: 10px;
  110. padding: 12px 20px;
  111. cursor: pointer;
  112. transition: background 0.15s;
  113. &:not(:last-child) {
  114. border-bottom: 1px solid var(--border-subtle, rgba(0, 0, 0, 0.05));
  115. }
  116. &:hover {
  117. background: var(--bg-subtle);
  118. }
  119. &--unread {
  120. background: var(--color-blue-bg);
  121. }
  122. }
  123. &__item-image {
  124. width: 36px;
  125. height: 36px;
  126. border-radius: 50%;
  127. object-fit: cover;
  128. flex-shrink: 0;
  129. }
  130. &__item-content {
  131. flex: 1;
  132. overflow: hidden;
  133. min-width: 0;
  134. }
  135. &__item-title {
  136. font-size: 0.8125rem;
  137. color: var(--text-primary);
  138. overflow: hidden;
  139. text-overflow: ellipsis;
  140. white-space: nowrap;
  141. &--unread {
  142. font-weight: 600;
  143. }
  144. &--read {
  145. font-weight: 400;
  146. }
  147. }
  148. &__item-message {
  149. font-size: 0.75rem;
  150. color: var(--text-muted);
  151. overflow: hidden;
  152. text-overflow: ellipsis;
  153. white-space: nowrap;
  154. margin-top: 1px;
  155. }
  156. &__item-time {
  157. font-size: 0.625rem;
  158. color: var(--text-muted);
  159. margin-top: 3px;
  160. }
  161. &__item-dot {
  162. width: 8px;
  163. height: 8px;
  164. border-radius: 50%;
  165. background: var(--color-blue);
  166. flex-shrink: 0;
  167. margin-top: 6px;
  168. }
  169. // ── 하단 푸터 ───────────────────────────────────────
  170. &__footer {
  171. display: flex;
  172. gap: 8px;
  173. padding: 12px 16px;
  174. border-top: 1px solid var(--border-default);
  175. }
  176. &__footer-btn {
  177. flex: 1;
  178. padding: 10px 12px;
  179. border-radius: 6px;
  180. text-align: center;
  181. font-size: 0.8125rem;
  182. font-weight: 600;
  183. text-decoration: none;
  184. transition: opacity 0.15s, background 0.15s;
  185. &--primary {
  186. background: var(--text-link);
  187. color: #fff;
  188. &:hover {
  189. opacity: 0.9;
  190. }
  191. }
  192. &--secondary {
  193. background: var(--bg-subtle);
  194. color: var(--text-primary);
  195. border: 1px solid var(--border-default);
  196. &:hover {
  197. background: var(--border-default);
  198. }
  199. }
  200. }
  201. }