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
240cbda0
Commit
240cbda0
authored
May 15, 2024
by
Timothy J. Baek
Browse files
fix: draggable items in sidebar
parent
d4c19306
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
34 additions
and
34 deletions
+34
-34
src/lib/components/chat/MessageInput.svelte
src/lib/components/chat/MessageInput.svelte
+1
-1
src/lib/components/layout/Sidebar.svelte
src/lib/components/layout/Sidebar.svelte
+33
-33
No files found.
src/lib/components/chat/MessageInput.svelte
View file @
240cbda0
...
@@ -535,7 +535,7 @@
...
@@ -535,7 +535,7 @@
</div>
</div>
<div class="bg-white dark:bg-gray-900">
<div class="bg-white dark:bg-gray-900">
<div class="max-w-6xl px-2.5
lg
:px-16 mx-auto inset-x-0">
<div class="max-w-6xl px-2.5
md
:px-16 mx-auto inset-x-0">
<div class=" pb-2">
<div class=" pb-2">
<input
<input
bind:this={filesInputElement}
bind:this={filesInputElement}
...
...
src/lib/components/layout/Sidebar.svelte
View file @
240cbda0
...
@@ -233,6 +233,7 @@
...
@@ -233,6 +233,7 @@
id="sidebar-new-chat-button"
id="sidebar-new-chat-button"
class="flex flex-1 justify-between rounded-xl px-2 py-2 hover:bg-gray-100 dark:hover:bg-gray-850 transition"
class="flex flex-1 justify-between rounded-xl px-2 py-2 hover:bg-gray-100 dark:hover:bg-gray-850 transition"
href="/"
href="/"
draggable="false"
on:click={async () => {
on:click={async () => {
selectedChatId = null;
selectedChatId = null;
...
@@ -308,6 +309,7 @@
...
@@ -308,6 +309,7 @@
selectedChatId = null;
selectedChatId = null;
chatId.set('');
chatId.set('');
}}
}}
draggable="false"
>
>
<div class="self-center">
<div class="self-center">
<svg
<svg
...
@@ -665,43 +667,41 @@
...
@@ -665,43 +667,41 @@
</div>
</div>
</div>
</div>
{#if $mobile}
<div class="px-2.5">
<div class="px-2.5">
<!-- <hr class=" border-gray-900 mb-1 w-full" /> -->
<!-- <hr class=" border-gray-900 mb-1 w-full" /> -->
<div class="flex flex-col">
<div class="flex flex-col">
{#if $user !== undefined}
{#if $user !== undefined}
<UserMenu
<UserMenu
role={$user.role}
role={$user.role}
on:show={(e) => {
on:show={(e) => {
if (e.detail === 'archived-chat') {
if (e.detail === 'archived-chat') {
showArchivedChats.set(true);
showArchivedChats.set(true);
}
}
}}
>
<button
class=" flex rounded-xl py-3 px-3.5 w-full hover:bg-gray-100 dark:hover:bg-gray-900 transition"
on:click={() => {
showDropdown = !showDropdown;
}}
}}
>
>
<button
<div class=" self-center mr-3">
class=" flex rounded-xl py-3 px-3.5 w-full hover:bg-gray-100 dark:hover:bg-gray-900 transition"
<img
on:click={() => {
src={$user.profile_image_url}
showDropdown = !showDropdown;
class=" max-w-[30px] object-cover rounded-full"
}}
alt="User profile"
>
/>
<div class=" self-center mr-3">
</div>
<img
<div class=" self-center font-semibold">{$user.name}</div>
src={$user.profile_image_url}
</button>
class=" max-w-[30px] object-cover rounded-full"
</UserMenu>
alt="User profile"
{/if}
/>
</div>
<div class=" self-center font-semibold">{$user.name}</div>
</button>
</UserMenu>
{/if}
</div>
</div>
</div>
{/if}
</div>
</div>
</div>
<div
<!--
<div
id="sidebar-handle"
id="sidebar-handle"
class=" hidden md:fixed left-0 top-[50dvh] -translate-y-1/2 transition-transform translate-x-[255px] md:translate-x-[260px] rotate-0"
class=" hidden md:fixed left-0 top-[50dvh] -translate-y-1/2 transition-transform translate-x-[255px] md:translate-x-[260px] rotate-0"
>
>
...
@@ -736,7 +736,7 @@
...
@@ -736,7 +736,7 @@
</span>
</span>
</button>
</button>
</Tooltip>
</Tooltip>
</div>
</div>
-->
</div>
</div>
<style>
<style>
...
...
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