diff --git a/src/components/navigation/SidebarBase.tsx b/src/components/navigation/SidebarBase.tsx index 4cf8b1a727d53be7a000e4d87419e536adb75e79..c751d7f77b8f08020447dd71584bb13d6d5a2c84 100644 --- a/src/components/navigation/SidebarBase.tsx +++ b/src/components/navigation/SidebarBase.tsx @@ -27,7 +27,7 @@ export const GenericSidebarList = styled.div` flex-grow: 1; overflow-y: scroll; - > svg { + > img { width: 100%; } `; diff --git a/src/components/navigation/left/HomeSidebar.tsx b/src/components/navigation/left/HomeSidebar.tsx index 13daf26494a77f7e260d4678b21a7e1a7284f2be..98cbc6e926a6808092331d9ee739a1a697b54b53 100644 --- a/src/components/navigation/left/HomeSidebar.tsx +++ b/src/components/navigation/left/HomeSidebar.tsx @@ -21,6 +21,8 @@ import { Link, Redirect, useLocation, useParams } from "react-router-dom"; import { useIntermediate } from "../../../context/intermediate/Intermediate"; import { useDMs, useForceUpdate, useUsers } from "../../../context/revoltjs/hooks"; +import placeholderSVG from "../items/placeholder.svg"; + type Props = WithDispatcher & { unreads: Unreads; } @@ -113,7 +115,7 @@ function HomeSidebar(props: Props) { action={() => openScreen({ id: "special_input", type: "create_group" })} /> </Localizer> - {channelsArr.length === 0 && <img src="/assets/images/placeholder.svg" />} + {channelsArr.length === 0 && <img src={placeholderSVG} />} {channelsArr.map(x => { let user; if (x.channel_type === 'DirectMessage') { diff --git a/src/context/revoltjs/RevoltClient.tsx b/src/context/revoltjs/RevoltClient.tsx index 85bec3b7a1677ae456d3a59695a55742824904af..5ca77857acb372ee7f2cc71607d311f02e6c649a 100644 --- a/src/context/revoltjs/RevoltClient.tsx +++ b/src/context/revoltjs/RevoltClient.tsx @@ -112,7 +112,7 @@ function Context({ auth, children, dispatcher }: Props) { logout: async shouldRequest => { dispatcher({ type: "LOGOUT" }); - delete client.user; + client.reset(); dispatcher({ type: "RESET" }); openScreen({ id: "none" });