feat: 完成Nacos配置优化和WebSocket集成

主要更新:
1. 统一所有微服务端口配置(19000-19008)
2. 为所有服务创建本地/测试/生产三套环境配置
3. 配置Nacos认证密码(本地:Peanut2817*#, 测试/生产:EmotionMuseum2025)
4. 优化网关路由配置,支持负载均衡和WebSocket
5. 新增emotion-websocket模块,支持实时聊天
6. 前端集成WebSocket,替代HTTP轮询
7. 添加配置验证和管理工具脚本

技术特性:
- 完整的环境隔离和服务发现
- WebSocket实时通信支持
- 负载均衡路由配置
- 跨域和安全配置
- 自动重连和心跳检测
This commit is contained in:
2025-07-17 18:10:45 +08:00
parent 9a3a8267b5
commit c77352877d
391 changed files with 46585 additions and 4294 deletions
+143
View File
@@ -0,0 +1,143 @@
@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+SC:wght@300;400;500;700&display=swap');
@import './variables.scss';
// 全局重置
* {
box-sizing: border-box;
margin: 0;
padding: 0;
}
html {
scroll-behavior: smooth;
}
body {
font-family: 'Noto Sans SC', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
font-size: $font-size-base;
line-height: 1.6;
color: $text-dark;
background-color: $light-gray;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}
// 滚动条样式
::-webkit-scrollbar {
width: 6px;
height: 6px;
}
::-webkit-scrollbar-track {
background: transparent;
}
::-webkit-scrollbar-thumb {
background: rgba(0, 0, 0, 0.2);
border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
background: rgba(0, 0, 0, 0.3);
}
// 工具类
.text-tech-blue {
color: $tech-blue !important;
}
.text-warm-orange {
color: $warm-orange !important;
}
.bg-tech-blue {
background-color: $tech-blue !important;
}
.bg-warm-orange {
background-color: $warm-orange !important;
}
.bg-light-gray {
background-color: $light-gray !important;
}
// 动画类
.fade-in-up {
animation: fadeInUp 0.8s ease-out forwards;
opacity: 0;
}
@keyframes fadeInUp {
from {
opacity: 0;
transform: translateY(20px);
}
to {
opacity: 1;
transform: translateY(0);
}
}
.scroll-target {
opacity: 0;
transform: translateY(30px);
transition: opacity 0.6s ease-out, transform 0.6s ease-out;
&.visible {
opacity: 1;
transform: translateY(0);
}
}
// 响应式工具类
.container {
width: 100%;
margin: 0 auto;
padding: 0 $spacing-md;
@media (min-width: $breakpoint-sm) {
max-width: 640px;
}
@media (min-width: $breakpoint-md) {
max-width: 768px;
}
@media (min-width: $breakpoint-lg) {
max-width: 1024px;
}
@media (min-width: $breakpoint-xl) {
max-width: 1280px;
}
@media (min-width: $breakpoint-xxl) {
max-width: 1536px;
}
}
// Ant Design 主题覆盖
.ant-btn-primary {
background-color: $tech-blue;
border-color: $tech-blue;
&:hover,
&:focus {
background-color: lighten($tech-blue, 10%);
border-color: lighten($tech-blue, 10%);
}
}
.ant-btn-orange {
background-color: $warm-orange;
border-color: $warm-orange;
color: white;
&:hover,
&:focus {
background-color: lighten($warm-orange, 10%);
border-color: lighten($warm-orange, 10%);
color: white;
}
}
@@ -0,0 +1,56 @@
// 主题色彩
$tech-blue: #4A90E2;
$warm-orange: #F5A623;
$white: #FFFFFF;
$light-gray: #F7F8FA;
$text-dark: #333333;
$text-medium: #888888;
// 间距
$spacing-xs: 4px;
$spacing-sm: 8px;
$spacing-md: 16px;
$spacing-lg: 24px;
$spacing-xl: 32px;
$spacing-xxl: 48px;
// 圆角
$border-radius-sm: 4px;
$border-radius-md: 8px;
$border-radius-lg: 12px;
$border-radius-xl: 16px;
$border-radius-full: 9999px;
// 阴影
$shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
$shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
$shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
$shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
// 断点
$breakpoint-sm: 640px;
$breakpoint-md: 768px;
$breakpoint-lg: 1024px;
$breakpoint-xl: 1280px;
$breakpoint-xxl: 1536px;
// 字体大小
$font-size-xs: 12px;
$font-size-sm: 14px;
$font-size-base: 16px;
$font-size-lg: 18px;
$font-size-xl: 20px;
$font-size-2xl: 24px;
$font-size-3xl: 30px;
$font-size-4xl: 36px;
// 字体权重
$font-weight-normal: 400;
$font-weight-medium: 500;
$font-weight-semibold: 600;
$font-weight-bold: 700;
// 过渡动画
$transition-fast: 0.15s ease-in-out;
$transition-normal: 0.3s ease-in-out;
$transition-slow: 0.5s ease-in-out;