customer-service-layout.html 5.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133
  1. <!-- 顶部导航栏 -->
  2. <header class="top-navbar">
  3. <div class="navbar-left">
  4. <button class="menu-toggle" (click)="toggleSidebar()">
  5. <svg width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor">
  6. <line x1="3" y1="12" x2="21" y2="12"></line>
  7. <line x1="3" y1="6" x2="21" y2="6"></line>
  8. <line x1="3" y1="18" x2="21" y2="18"></line>
  9. </svg>
  10. </button>
  11. <h1 class="app-title">客服工作台</h1>
  12. </div>
  13. <div class="navbar-center">
  14. <div class="search-container">
  15. <input
  16. type="text"
  17. [(ngModel)]="searchTerm"
  18. placeholder="搜索项目、客户或动态..."
  19. class="search-input"
  20. (keyup.enter)="handleSearch()"
  21. />
  22. <button class="search-button" (click)="handleSearch()">
  23. <svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor">
  24. <circle cx="11" cy="11" r="8"></circle>
  25. <path d="m21 21-4.35-4.35"></path>
  26. </svg>
  27. </button>
  28. </div>
  29. </div>
  30. <div class="navbar-right">
  31. <button class="notification-btn" (click)="toggleNotifications()">
  32. <svg width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor">
  33. <path d="M12 22s8-4 8-10V5l-8-3-8 3v7c0 6 8 10 8 10z"></path>
  34. </svg>
  35. <span class="notification-badge">{{ notifications().length }}</span>
  36. </button>
  37. <!-- 通知下拉菜单 -->
  38. @if (showNotifications()) {
  39. <div class="notification-dropdown">
  40. <div class="notification-header">
  41. <h3>消息通知</h3>
  42. <button class="close-btn" (click)="toggleNotifications()">
  43. <svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor">
  44. <line x1="18" y1="6" x2="6" y2="18"></line>
  45. <line x1="6" y1="6" x2="18" y2="18"></line>
  46. </svg>
  47. </button>
  48. </div>
  49. <div class="notification-list">
  50. @for (notification of notifications(); track notification) {
  51. <div class="notification-item">
  52. <div class="notification-icon">
  53. <svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor">
  54. <circle cx="12" cy="12" r="10"></circle>
  55. <line x1="12" y1="8" x2="12" y2="12"></line>
  56. <line x1="12" y1="16" x2="12.01" y2="16"></line>
  57. </svg>
  58. </div>
  59. <div class="notification-content">
  60. <p>{{ notification }}</p>
  61. </div>
  62. </div>
  63. }
  64. </div>
  65. <div class="notification-footer">
  66. <a href="#" class="view-all">查看全部</a>
  67. </div>
  68. </div>
  69. }
  70. <div class="user-profile">
  71. <div style="width: 40px; height: 40px; background-color: #FFCCCC; color: #555555; display: flex; align-items: center; justify-content: center; font-size: 13.333333333333334px; font-weight: bold;" class="user-avatar" title="用户头像">CS</div>
  72. <span class="user-name">客服小李</span>
  73. </div>
  74. </div>
  75. </header>
  76. <!-- 主要内容区 -->
  77. <main class="main-content">
  78. <!-- 左侧侧边栏 -->
  79. <aside class="sidebar" [class.collapsed]="!sidebarOpen">
  80. <nav class="sidebar-nav">
  81. <a routerLink="/customer-service/dashboard" class="nav-item" routerLinkActive="active">
  82. <svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor">
  83. <path d="M3 13h8V3H3v10zm0 8h8v-6H3v6zm10 0h8V11h-8v10zm0-18v6h8V3h-8z"></path>
  84. </svg>
  85. <span>工作台</span>
  86. </a>
  87. <a routerLink="/customer-service/project-list" class="nav-item" routerLinkActive="active">
  88. <svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor">
  89. <line x1="8" y1="6" x2="21" y2="6"></line>
  90. <line x1="8" y1="12" x2="21" y2="12"></line>
  91. <line x1="8" y1="18" x2="21" y2="18"></line>
  92. <line x1="3" y1="6" x2="3.01" y2="6"></line>
  93. <line x1="3" y1="12" x2="3.01" y2="12"></line>
  94. <line x1="3" y1="18" x2="3.01" y2="18"></line>
  95. </svg>
  96. <span>项目列表</span>
  97. </a>
  98. <a routerLink="/customer-service/case-library" class="nav-item" routerLinkActive="active">
  99. <svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor">
  100. <path d="M2 3h6a4 4 0 0 1 4 4v14a3 3 0 0 0-3-3H2z"></path>
  101. <path d="M22 3h-6a4 4 0 0 0-4 4v14a3 3 0 0 1 3-3h7z"></path>
  102. </svg>
  103. <span>案例库</span>
  104. </a>
  105. </nav>
  106. <div class="sidebar-footer">
  107. <div class="storage-info">
  108. <span>在线时长: 4.5h</span>
  109. </div>
  110. <button class="logout-btn" (click)="logout()">
  111. <svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor">
  112. <path d="M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4"></path>
  113. <polyline points="16 17 21 12 16 7"></polyline>
  114. <line x1="21" y1="12" x2="9" y2="12"></line>
  115. </svg>
  116. <span>退出登录</span>
  117. </button>
  118. </div>
  119. </aside>
  120. <!-- 中间内容区 -->
  121. <div class="content-wrapper" [class.expanded]="!sidebarOpen">
  122. <router-outlet />
  123. </div>
  124. </main>