From d8bdfe1dd4fb59e0a4eaf697234be73a8e29f62d Mon Sep 17 00:00:00 2001 From: wangdl Date: Sat, 6 Jun 2026 18:10:00 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20AddKnowledgePage=20=E6=A0=87=E7=AD=BE?= =?UTF-8?q?=E6=94=BE=E5=A4=A7=20+=20=E6=96=87=E4=BB=B6=E5=90=8D=E7=82=B9?= =?UTF-8?q?=E5=87=BB=E5=A4=8D=E5=88=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 标签字号 12→15 (内容来源/标题/内容) - 文件列表项点击文件名复制到剪贴板 - 提示文字 12→13 Co-Authored-By: Claude Opus 4.7 --- .../Features/Library/LibrarySubpages.swift | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/AIStudyApp/AIStudyApp/Features/Library/LibrarySubpages.swift b/AIStudyApp/AIStudyApp/Features/Library/LibrarySubpages.swift index c233039..25c9e56 100644 --- a/AIStudyApp/AIStudyApp/Features/Library/LibrarySubpages.swift +++ b/AIStudyApp/AIStudyApp/Features/Library/LibrarySubpages.swift @@ -643,7 +643,7 @@ struct AddKnowledgePage: View { ScrollView { VStack(spacing: 16) { // 内容来源选择 VStack(alignment: .leading, spacing: 8) { - Text("内容来源").font(.system(size: 12, weight: .semibold)).foregroundColor(Color.zxF035) + Text("内容来源").font(.system(size: 15, weight: .semibold)).foregroundColor(Color.zxF035) Picker("", selection: $sourceType) { ForEach(SourceType.allCases, id: \.self) { t in Text(t.rawValue).tag(t) } } @@ -654,14 +654,14 @@ struct AddKnowledgePage: View { switch sourceType { case .manual: VStack(alignment: .leading, spacing: 8) { - Text("标题").font(.system(size: 12, weight: .semibold)).foregroundColor(Color.zxF035) + Text("标题").font(.system(size: 15, weight: .semibold)).foregroundColor(Color.zxF035) TextField("输入知识点标题", text: $title).font(.system(size: 16)).tint(Color.zxPurple) .padding(.horizontal, 16).frame(height: 52) .background(Color.zxFill004).clipShape(RoundedRectangle(cornerRadius: 14)) .overlay(RoundedRectangle(cornerRadius: 14).stroke(Color.zxBorder008, lineWidth: 1)) } VStack(alignment: .leading, spacing: 8) { - Text("内容").font(.system(size: 12, weight: .semibold)).foregroundColor(Color.zxF035) + Text("内容").font(.system(size: 15, weight: .semibold)).foregroundColor(Color.zxF035) TextEditor(text: $content) .frame(minHeight: 200).scrollContentBackground(.hidden).padding(12) .background(Color.zxFill004).clipShape(RoundedRectangle(cornerRadius: 14)) @@ -701,7 +701,8 @@ struct AddKnowledgePage: View { ForEach(selectedFiles) { f in HStack(spacing: 8) { Image(systemName: f.icon).foregroundColor(Color.zxGreen) - Text(f.name).font(.system(size: 14)).foregroundColor(Color.zxF0).lineLimit(1) + Text(f.name).font(.system(size: 15)).foregroundColor(Color.zxF0).lineLimit(1) + .onTapGesture { UIPasteboard.general.string = f.name } Spacer() Text(f.size).font(.system(size: 12)).foregroundColor(Color.zxF04) Button { @@ -721,7 +722,7 @@ struct AddKnowledgePage: View { Image(systemName: "info.circle").font(.system(size: 12)) Text("支持多选,每个文件生成一个知识点") } - .font(.system(size: 12)).foregroundColor(Color.zxF04) + .font(.system(size: 13)).foregroundColor(Color.zxF04) } if isUploading { @@ -1362,8 +1363,8 @@ struct EditKnowledgePage: View { var body: some View { ZStack { Color.zxBg0.ignoresSafeArea(); VStack(spacing: 0) { ScrollView { VStack(spacing: 16) { - VStack(alignment: .leading, spacing: 8) { Text("标题").font(.system(size: 12, weight: .semibold)).foregroundColor(Color.zxF035); TextField("", text: $title).font(.system(size: 16)).tint(Color.zxPurple).padding(.horizontal, 16).frame(height: 52).background(Color.zxFill004).clipShape(RoundedRectangle(cornerRadius: 14)).overlay(RoundedRectangle(cornerRadius: 14).stroke(Color.zxBorder008, lineWidth: 1)) } - VStack(alignment: .leading, spacing: 8) { Text("内容").font(.system(size: 12, weight: .semibold)).foregroundColor(Color.zxF035); TextEditor(text: $content).frame(minHeight: 200).scrollContentBackground(.hidden).padding(12).background(Color.zxFill004).clipShape(RoundedRectangle(cornerRadius: 14)).overlay(RoundedRectangle(cornerRadius: 14).stroke(Color.zxBorder008, lineWidth: 1)) } + VStack(alignment: .leading, spacing: 8) { Text("标题").font(.system(size: 15, weight: .semibold)).foregroundColor(Color.zxF035); TextField("", text: $title).font(.system(size: 16)).tint(Color.zxPurple).padding(.horizontal, 16).frame(height: 52).background(Color.zxFill004).clipShape(RoundedRectangle(cornerRadius: 14)).overlay(RoundedRectangle(cornerRadius: 14).stroke(Color.zxBorder008, lineWidth: 1)) } + VStack(alignment: .leading, spacing: 8) { Text("内容").font(.system(size: 15, weight: .semibold)).foregroundColor(Color.zxF035); TextEditor(text: $content).frame(minHeight: 200).scrollContentBackground(.hidden).padding(12).background(Color.zxFill004).clipShape(RoundedRectangle(cornerRadius: 14)).overlay(RoundedRectangle(cornerRadius: 14).stroke(Color.zxBorder008, lineWidth: 1)) } Button { Task { _ = try? await KnowledgeItemService.shared.update(id: item.id, title: title, content: content, summary: nil) } } label: { Text("保存修改").font(.system(size: 14, weight: .bold)).foregroundColor(.white).frame(maxWidth: .infinity).frame(height: 52).background(ZXGradient.ctaPurple).clipShape(RoundedRectangle(cornerRadius: 16)) }