diff --git a/src/lib/components/layout/Sidebar.svelte b/src/lib/components/layout/Sidebar.svelte index 12c04c060..e7cb72de6 100644 --- a/src/lib/components/layout/Sidebar.svelte +++ b/src/lib/components/layout/Sidebar.svelte @@ -22,6 +22,7 @@ import ShareChatModal from '../chat/ShareChatModal.svelte'; import ArchiveBox from '../icons/ArchiveBox.svelte'; import ArchivedChatsModal from './Sidebar/ArchivedChatsModal.svelte'; + import UserMenu from './Sidebar/UserMenu.svelte'; const BREAKPOINT = 1024; @@ -685,163 +686,30 @@
{#if $user !== undefined} - - - {#if showDropdown} -
diff --git a/src/lib/components/layout/Sidebar/UserMenu.svelte b/src/lib/components/layout/Sidebar/UserMenu.svelte new file mode 100644 index 000000000..c7618ef5d --- /dev/null +++ b/src/lib/components/layout/Sidebar/UserMenu.svelte @@ -0,0 +1,172 @@ + + + { + dispatch('change', state); + }} +> + + + + + + fade(e, { duration: 100 })} + > + {#if role === 'admin'} + + + + {/if} + + + + + +
+ + + + +
+
+