From 2dfc1c068f2c528c93adef1138a7551d3a5d5391 Mon Sep 17 00:00:00 2001 From: JefferyHcool <1063474837@qq.com> Date: Fri, 6 Jun 2025 22:02:02 +0800 Subject: [PATCH 1/6] =?UTF-8?q?feat(NoteForm):=20=E5=A2=9E=E5=8A=A0?= =?UTF-8?q?=E6=96=87=E4=BB=B6=E4=B8=8A=E4=BC=A0=E7=8A=B6=E6=80=81=E5=8F=8D?= =?UTF-8?q?=E9=A6=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 添加上传中和上传成功状态的显示- 优化上传逻辑,增加状态控制 - 提升用户体验,明确上传过程 --- .../pages/HomePage/components/NoteForm.tsx | 29 ++++++++++++++----- 1 file changed, 22 insertions(+), 7 deletions(-) diff --git a/BillNote_frontend/src/pages/HomePage/components/NoteForm.tsx b/BillNote_frontend/src/pages/HomePage/components/NoteForm.tsx index d9f21b3..d9cc6bf 100644 --- a/BillNote_frontend/src/pages/HomePage/components/NoteForm.tsx +++ b/BillNote_frontend/src/pages/HomePage/components/NoteForm.tsx @@ -7,7 +7,7 @@ import { FormLabel, FormMessage, } from '@/components/ui/form.tsx' -import { useEffect } from 'react' +import { useEffect,useState } from 'react' import { useForm, useWatch } from 'react-hook-form' import { zodResolver } from '@hookform/resolvers/zod' import { z } from 'zod' @@ -119,6 +119,9 @@ const CheckboxGroup = ({ /* -------------------- 主组件 -------------------- */ const NoteForm = () => { + + const [isUploading, setIsUploading] = useState(false) + const [uploadSuccess, setUploadSuccess] = useState(false) /* ---- 全局状态 ---- */ const { addPendingTask, currentTaskId, setCurrentTask, getCurrentTask, retryTask } = useTaskStore() @@ -185,12 +188,18 @@ const NoteForm = () => { const handleFileUpload = async (file: File, cb: (url: string) => void) => { const formData = new FormData() formData.append('file', file) + setIsUploading(true) + setUploadSuccess(false) + try { - const { data } = await uploadFile(formData) - if (data.code === 0) cb(data.data.url) + const data = await uploadFile(formData) + cb(data.url) + setUploadSuccess(true) } catch (err) { console.error('上传失败:', err) message.error('上传失败,请重试') + } finally { + setIsUploading(false) } } @@ -335,10 +344,16 @@ const NoteForm = () => { input.click() }} > -

- 拖拽文件到这里上传
- 或点击选择文件 -

+ {isUploading ? ( +

上传中,请稍候…

+ ) : uploadSuccess ? ( +

上传成功!

+ ) : ( +

+ 拖拽文件到这里上传
+ 或点击选择文件 +

+ )} )} From cf512e226fc037c38d4665b9f5c0b67298a715be Mon Sep 17 00:00:00 2001 From: JefferyHcool <1063474837@qq.com> Date: Fri, 6 Jun 2025 22:03:12 +0800 Subject: [PATCH 2/6] =?UTF-8?q?feat:=E4=BC=98=E5=8C=96=E4=B8=8A=E4=BC=A0?= =?UTF-8?q?=E4=BD=93=E9=AA=8C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- BillNote_frontend/src/pages/SettingPage/about.tsx | 2 +- README.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/BillNote_frontend/src/pages/SettingPage/about.tsx b/BillNote_frontend/src/pages/SettingPage/about.tsx index 14fcfc0..44059e3 100644 --- a/BillNote_frontend/src/pages/SettingPage/about.tsx +++ b/BillNote_frontend/src/pages/SettingPage/about.tsx @@ -26,7 +26,7 @@ export default function AboutPage() { height={50} className="rounded-lg" /> -

BiliNote v1.7.4

+

BiliNote v1.7.5

AI 视频笔记生成工具 让 AI 为你的视频做笔记 diff --git a/README.md b/README.md index 201964c..dd079d9 100644 --- a/README.md +++ b/README.md @@ -3,7 +3,7 @@

BiliNote Banner

-

BiliNote v1.7.4

+

BiliNote v1.7.5

AI 视频笔记生成工具 让 AI 为你的视频做笔记

From 032446d5eb1fa4aeda8e01bc3c69a53b03009449 Mon Sep 17 00:00:00 2001 From: JefferyHcool <1063474837@qq.com> Date: Fri, 6 Jun 2025 22:15:31 +0800 Subject: [PATCH 3/6] =?UTF-8?q?fix=EF=BC=9A=E4=BF=AE=E5=A4=8Dbugs?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- backend/app/services/note.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/app/services/note.py b/backend/app/services/note.py index 1e9ef8b..c1332b9 100644 --- a/backend/app/services/note.py +++ b/backend/app/services/note.py @@ -436,7 +436,7 @@ class NoteGenerator: logger.info(f"转写并缓存成功 ({transcript_cache_file})") return transcript except Exception as exc: - logger.error(f"音频转写失败:{e}") + logger.error(f"音频转写失败:{exc}") self._handle_exception(task_id, exc) raise From 5e63630033feb690b530bb24765a03b61abae907 Mon Sep 17 00:00:00 2001 From: Jianwu Huang <63531681+JefferyHcool@users.noreply.github.com> Date: Sun, 8 Jun 2025 11:12:03 +0800 Subject: [PATCH 4/6] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index dd079d9..d6cdf0c 100644 --- a/README.md +++ b/README.md @@ -121,7 +121,7 @@ sudo apt install ffmpeg - BiliNote 交流QQ群:785367111 - BiliNote 交流微信群: - wechat + wechat From 4a0f4832243e6b156f0430e0fe36c296a914e42f Mon Sep 17 00:00:00 2001 From: Jianwu Huang <63531681+JefferyHcool@users.noreply.github.com> Date: Sun, 8 Jun 2025 18:12:54 +0800 Subject: [PATCH 5/6] Update README.md --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index d6cdf0c..72ef454 100644 --- a/README.md +++ b/README.md @@ -26,8 +26,8 @@ BiliNote 是一个开源的 AI 视频笔记助手,支持通过哔哩哔哩、Y ## 📝 使用文档 详细文档可以查看[这里](https://docs.bilinote.app/) - - +## 体验地址 +可以通过访问 [这里](https://www.bilinote.app/) 进行体验,速度略慢,不支持长视频。 ## 📦 Windows 打包版 本项目提供了 Windows 系统的 exe 文件,可在[release](https://github.com/JefferyHcool/BiliNote/releases/tag/v1.1.1)进行下载。**注意一定要在没有中文路径的环境下运行。** From 7d9d47d7b78661cd65cb4ed4eea8040dedaf73c5 Mon Sep 17 00:00:00 2001 From: Jianwu Huang <63531681+JefferyHcool@users.noreply.github.com> Date: Thu, 19 Jun 2025 16:21:14 +0800 Subject: [PATCH 6/6] Create workflow.yml --- .github/workflows/main.yml | 59 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 .github/workflows/main.yml diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml new file mode 100644 index 0000000..03566bb --- /dev/null +++ b/.github/workflows/main.yml @@ -0,0 +1,59 @@ +# .github/workflows/release.yml +name: Build Desktop App (Python Backend + Tauri Frontend) + +on: + push: + tags: + - 'v*' # 发布 tag 时触发 + +jobs: + build: + strategy: + matrix: + platform: [macos-latest, ubuntu-latest, windows-latest] + + runs-on: ${{ matrix.platform }} + + steps: + - name: Checkout Code + uses: actions/checkout@v3 + + # 设置 Python 环境 + - name: Set up Python + uses: actions/setup-python@v4 + with: + python-version: '3.10' + + # 安装 Python 依赖并执行你的 build.sh + - name: Install Python dependencies & Build backend + run: | + python -m pip install --upgrade pip + pip install -r backend/requirements.txt + chmod +x backend/build.sh + ./backend/build.sh + + # 设置 Node 环境 + 安装前端依赖 + - name: Set up Node.js + uses: actions/setup-node@v3 + with: + node-version: '20' + + - name: Enable Corepack + Install pnpm + run: | + corepack enable + pnpm install + + # 设置 Rust 环境 + - name: Set up Rust + uses: dtolnay/rust-toolchain@stable + + # 打包 Tauri 应用 + - name: Build Tauri App + run: pnpm tauri build + + # 可选:上传构建产物 + - name: Upload Desktop Bundle + uses: actions/upload-artifact@v3 + with: + name: app-${{ matrix.platform }} + path: src-tauri/target/release/bundle/