diff --git a/src/components/Sidebar/index.jsx b/src/components/Sidebar/index.jsx index 2f90d538..30aeb636 100644 --- a/src/components/Sidebar/index.jsx +++ b/src/components/Sidebar/index.jsx @@ -19,7 +19,7 @@ import useSidebarStyles from './style' import SafeList from './SafeList' import { WELCOME_ADDRESS } from '~/routes/routes' -const { useState } = React +const { useState, useEffect } = React type TSidebarContext = { isOpen: boolean, @@ -51,6 +51,10 @@ const Sidebar = ({ const [filter, setFilter] = useState('') const classes = useSidebarStyles() + useEffect(() => { + setFilter('') + }, [isOpen]) + const searchClasses = { input: classes.searchInput, root: classes.searchRoot,