Skip to content

armgit / chops

Public Imported from GitHub
0

Your AI agent skills, finally organized. A macOS app to browse, edit, and manage skills across Claude Code, Cursor, Codex, Windsurf, and Amp.

Add Enter shortcut for new collections (#30)

gula00a791121aea1c
diff --git a/Chops/Views/Sidebar/CollectionListView.swift b/Chops/Views/Sidebar/CollectionListView.swift
index a049a0f..b3fb872 100644
--- a/Chops/Views/Sidebar/CollectionListView.swift
+++ b/Chops/Views/Sidebar/CollectionListView.swift
@@ -137,6 +137,8 @@ struct CollectionListView: View {
VStack(spacing: 12) {
TextField("Collection name", text: $newCollectionName)
.textFieldStyle(.roundedBorder)
+ .submitLabel(.done)
+ .onSubmit(createCollection)
if let errorMessage {
Text(errorMessage)
@@ -169,10 +171,8 @@ struct CollectionListView: View {
showingNewCollection = false
}
Spacer()
- Button("Create") {
- createCollection()
- }
- .disabled(newCollectionName.isEmpty)
+ Button("Create", action: createCollection)
+ .disabled(normalizedName(newCollectionName).isEmpty)
}
}
.padding()