update pay function
This commit is contained in:
@@ -44,7 +44,10 @@
|
||||
**前端**
|
||||
- **核心框架**: React 18.3.1
|
||||
- **类型系统**: TypeScript 5.9.3(渐进式接入中,支持 JS/TS 混合开发)
|
||||
- **UI 组件库**: Chakra UI 2.10.9(主要) + Ant Design 5.27.4(表格/表单)
|
||||
- **UI 组件库**:
|
||||
- Chakra UI 2.10.9(主要,全局使用)
|
||||
- Ant Design 5.27.4(表格/表单)
|
||||
- **HeroUI 3.0.0-beta**(AgentChat 专用,2025-11-22 升级)
|
||||
- **状态管理**: Redux Toolkit 2.9.2
|
||||
- **路由**: React Router v6.30.1 配合 React.lazy() 实现代码分割
|
||||
- **构建系统**: CRACO 7.1.0 + 激进的 webpack 5 优化
|
||||
@@ -58,7 +61,8 @@
|
||||
- **开发工具**: MSW (Mock Service Worker) 用于 API mocking
|
||||
- **虚拟化**: @tanstack/react-virtual 3.13.12(性能优化)
|
||||
- **其他**: Draft.js(富文本编辑)、React Markdown、React Quill
|
||||
- Use HeroUI v3 documentation from https://v3.heroui.com/llms.txt
|
||||
|
||||
**注意**: HeroUI v3 文档参考 https://v3.heroui.com/llms.txt,详细升级说明见 [HEROUI_V3_UPGRADE_GUIDE.md](./HEROUI_V3_UPGRADE_GUIDE.md)
|
||||
|
||||
**后端**
|
||||
- Flask + SQLAlchemy ORM
|
||||
|
||||
@@ -18,7 +18,8 @@
|
||||
"@fullcalendar/daygrid": "^5.9.0",
|
||||
"@fullcalendar/interaction": "^5.9.0",
|
||||
"@fullcalendar/react": "^5.9.0",
|
||||
"@heroui/react": "^2.8.5",
|
||||
"@heroui/react": "beta",
|
||||
"@heroui/styles": "beta",
|
||||
"@reduxjs/toolkit": "^2.9.2",
|
||||
"@splidejs/react-splide": "^0.7.12",
|
||||
"@tanstack/react-virtual": "^3.13.12",
|
||||
|
||||
@@ -2,6 +2,10 @@
|
||||
import React from 'react';
|
||||
import ReactDOM from 'react-dom/client';
|
||||
import { BrowserRouter as Router } from 'react-router-dom';
|
||||
|
||||
// 导入 HeroUI v3 样式(必须在最前面导入,包含 Tailwind CSS)
|
||||
import './styles/heroui.css';
|
||||
|
||||
// 导入 Brainwave 样式(空文件,保留以避免错误)
|
||||
import './styles/brainwave.css';
|
||||
|
||||
|
||||
@@ -3,7 +3,6 @@
|
||||
|
||||
import React from 'react';
|
||||
import { ChakraProvider } from '@chakra-ui/react';
|
||||
import { HeroUIProvider } from '@heroui/react';
|
||||
import { Provider as ReduxProvider } from 'react-redux';
|
||||
|
||||
// Redux Store
|
||||
@@ -23,11 +22,11 @@ import { NotificationProvider } from '../contexts/NotificationContext';
|
||||
* Provider 层级顺序 (从外到内):
|
||||
* 1. ReduxProvider - 状态管理层
|
||||
* 2. ChakraProvider - UI 框架层(主要)
|
||||
* 3. HeroUIProvider - Hero UI 框架层(AgentChat 专用)
|
||||
* 4. NotificationProvider - 通知系统
|
||||
* 5. AuthProvider - 认证系统
|
||||
* 3. NotificationProvider - 通知系统
|
||||
* 4. AuthProvider - 认证系统
|
||||
*
|
||||
* 注意:
|
||||
* - HeroUI v3 不再需要 HeroUIProvider,样式通过 CSS 导入加载 (src/styles/heroui.css)
|
||||
* - AuthModal 已迁移到 Redux (authModalSlice + useAuthModal Hook)
|
||||
* - ErrorBoundary 在各 Layout 层实现,不在全局层,以实现精细化错误隔离
|
||||
* - MainLayout: PageTransitionWrapper 包含 ErrorBoundary (页面错误不影响导航栏)
|
||||
@@ -49,13 +48,11 @@ export function AppProviders({ children }) {
|
||||
}
|
||||
}}
|
||||
>
|
||||
<HeroUIProvider>
|
||||
<NotificationProvider>
|
||||
<AuthProvider>
|
||||
{children}
|
||||
</AuthProvider>
|
||||
</NotificationProvider>
|
||||
</HeroUIProvider>
|
||||
</ChakraProvider>
|
||||
</ReduxProvider>
|
||||
);
|
||||
|
||||
19
src/styles/heroui.css
Normal file
19
src/styles/heroui.css
Normal file
@@ -0,0 +1,19 @@
|
||||
/* HeroUI v3 样式导入 */
|
||||
/* 文档: https://v3.heroui.com/docs/quick-start */
|
||||
|
||||
/*
|
||||
* 重要: 必须先导入 tailwindcss,再导入 @heroui/styles
|
||||
* HeroUI v3 不再使用 Tailwind 插件,而是通过 CSS 层叠方式加载样式
|
||||
*/
|
||||
@import "tailwindcss";
|
||||
@import "@heroui/styles";
|
||||
|
||||
/*
|
||||
* AgentChat 页面的自定义样式
|
||||
* 这些样式仅在使用 HeroUI 组件的页面生效
|
||||
*/
|
||||
|
||||
/* 确保深色模式正常工作 */
|
||||
.dark {
|
||||
color-scheme: dark;
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -1,11 +1,12 @@
|
||||
/** @type {import('tailwindcss').Config} */
|
||||
const { heroui } = require("@heroui/react");
|
||||
|
||||
module.exports = {
|
||||
// 只扫描 AgentChat 页面(唯一使用 Hero UI 的地方)
|
||||
// 使用精确路径,避免误匹配 node_modules
|
||||
content: [
|
||||
"./src/views/AgentChat/**/*.{js,jsx}",
|
||||
"./src/views/AgentChat/index.js",
|
||||
"./src/providers/AppProviders.js", // HeroUIProvider
|
||||
// HeroUI v3 不再需要扫描 node_modules,样式通过 CSS 导入加载
|
||||
],
|
||||
|
||||
darkMode: "class",
|
||||
@@ -14,5 +15,6 @@ module.exports = {
|
||||
extend: {},
|
||||
},
|
||||
|
||||
plugins: [heroui()],
|
||||
// HeroUI v3 不再需要 plugins,样式通过 @import "@heroui/styles" 加载
|
||||
plugins: [],
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user