Add combine saved conversations feature (simple + AI-assisted merge)
Lets users multi-select 2+ saved conversations and merge them into one, either by chronological concatenation or by having the default model synthesize a single coherent conversation from the source transcripts. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -36,6 +36,7 @@ struct ConversationListView: View {
|
||||
@State private var semanticResults: [Conversation] = []
|
||||
@State private var isSearching = false
|
||||
@State private var selectedIndex: Int = 0
|
||||
@State private var showCombineSheet = false
|
||||
@FocusState private var searchFocused: Bool
|
||||
private let settings = SettingsService.shared
|
||||
var onLoad: ((Conversation) -> Void)?
|
||||
@@ -70,6 +71,18 @@ struct ConversationListView: View {
|
||||
}
|
||||
.buttonStyle(.plain)
|
||||
|
||||
if selectedConversations.count >= 2 {
|
||||
Button {
|
||||
showCombineSheet = true
|
||||
} label: {
|
||||
HStack(spacing: 4) {
|
||||
Image(systemName: "arrow.triangle.merge")
|
||||
Text("Combine (\(selectedConversations.count))")
|
||||
}
|
||||
}
|
||||
.buttonStyle(.plain)
|
||||
}
|
||||
|
||||
if !selectedConversations.isEmpty {
|
||||
Button(role: .destructive) {
|
||||
deleteSelected()
|
||||
@@ -298,6 +311,16 @@ struct ConversationListView: View {
|
||||
searchFocused = true
|
||||
}
|
||||
.frame(minWidth: 700, idealWidth: 800, minHeight: 500, idealHeight: 600)
|
||||
.sheet(isPresented: $showCombineSheet) {
|
||||
CombineConversationsSheet(
|
||||
conversations: conversations.filter { selectedConversations.contains($0.id) },
|
||||
onCompleted: { _ in
|
||||
loadConversations()
|
||||
selectedConversations.removeAll()
|
||||
isSelecting = false
|
||||
}
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
private func loadConversations() {
|
||||
|
||||
Reference in New Issue
Block a user