improve preset editor

This commit is contained in:
josc146
2024-03-26 13:43:27 +08:00
parent edf55843e4
commit d6b536ace9
6 changed files with 86 additions and 42 deletions

View File

@@ -74,6 +74,7 @@ class CommonStore {
conversation: Conversation = {};
conversationOrder: string[] = [];
activePreset: Preset | null = null;
activePresetIndex: number = -1;
attachmentUploading: boolean = false;
attachments: {
[uuid: string]: Attachment[]
@@ -342,7 +343,7 @@ class CommonStore {
this.lastUnfinishedModelDownloads = value;
}
setEditingPreset(value: Preset) {
setEditingPreset(value: Preset | null) {
this.editingPreset = value;
}
@@ -356,6 +357,10 @@ class CommonStore {
this.activePreset = value;
}
setActivePresetIndex(value: number) {
this.activePresetIndex = value;
}
setCompletionSubmittedPrompt(value: string) {
this.completionSubmittedPrompt = value;
}