Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
chenpangpang
open-webui
Commits
5d0b77e6
Commit
5d0b77e6
authored
Jun 16, 2024
by
Timothy J. Baek
Browse files
fix: shift delete
parent
a4810a5e
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
4 deletions
+8
-4
src/lib/components/layout/Sidebar.svelte
src/lib/components/layout/Sidebar.svelte
+7
-3
src/lib/components/layout/Sidebar/ChatItem.svelte
src/lib/components/layout/Sidebar/ChatItem.svelte
+1
-1
No files found.
src/lib/components/layout/Sidebar.svelte
View file @
5d0b77e6
...
@@ -464,9 +464,13 @@
...
@@ -464,9 +464,13 @@
on:select={() => {
on:select={() => {
selectedChatId = chat.id;
selectedChatId = chat.id;
}}
}}
on:delete={() => {
on:delete={(e) => {
if ((e?.detail ?? '') === 'shift') {
deleteChatHandler(chat.id);
} else {
deleteChat = chat;
deleteChat = chat;
showDeleteConfirm = true;
showDeleteConfirm = true;
}
}}
}}
/>
/>
{/each}
{/each}
...
...
src/lib/components/layout/Sidebar/ChatItem.svelte
View file @
5d0b77e6
...
@@ -201,7 +201,7 @@
...
@@ -201,7 +201,7 @@
<button
<button
class=" self-center dark:hover:text-white transition"
class=" self-center dark:hover:text-white transition"
on:click={() => {
on:click={() => {
d
eleteChat(chat.id
);
d
ispatch('delete', 'shift'
);
}}
}}
type="button"
type="button"
>
>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment