chore: update location store handler (#1273)

* chore: update location store handler

* chore: update search bar
This commit is contained in:
boojack
2023-03-05 19:50:50 +08:00
committed by GitHub
parent 6d9ead80b2
commit 5d24fe189d
5 changed files with 13 additions and 143 deletions

View File

@ -1,6 +1,4 @@
import { isUndefined } from "lodash-es";
import { useEffect } from "react";
import { useLocationStore } from "../store/module";
import ShortcutList from "./ShortcutList";
import TagList from "./TagList";
import SearchBar from "./SearchBar";
@ -8,13 +6,6 @@ import UsageHeatMap from "./UsageHeatMap";
import "../less/home-sidebar.less";
const HomeSidebar = () => {
const locationStore = useLocationStore();
const query = locationStore.state.query;
useEffect(() => {
toggleHomeSidebar(false);
}, [query]);
return (
<>
<div className="mask" onClick={() => toggleHomeSidebar(false)}></div>