cleanup search documents action
This commit is contained in:
@@ -23,11 +23,7 @@ import stores from "~/stores";
|
||||
import SearchQuery from "~/models/SearchQuery";
|
||||
import KeyboardShortcuts from "~/scenes/KeyboardShortcuts";
|
||||
import { createAction } from "~/actions";
|
||||
import {
|
||||
NavigationSection,
|
||||
SearchSection,
|
||||
RecentSearchesSection,
|
||||
} from "~/actions/sections";
|
||||
import { NavigationSection, RecentSearchesSection } from "~/actions/sections";
|
||||
import history from "~/utils/history";
|
||||
import {
|
||||
organizationSettingsPath,
|
||||
@@ -57,17 +53,6 @@ export const navigateToRecentSearchQuery = (searchQuery: SearchQuery) =>
|
||||
perform: () => history.push(searchPath(searchQuery.query)),
|
||||
});
|
||||
|
||||
export const navigateToSearchQuery = (searchQuery: string) =>
|
||||
createAction({
|
||||
id: "search",
|
||||
section: SearchSection,
|
||||
name: ({ t }) =>
|
||||
t(`Search documents for "{{searchQuery}}"`, { searchQuery }),
|
||||
icon: <SearchIcon />,
|
||||
perform: () => history.push(searchPath(searchQuery)),
|
||||
visible: ({ location }) => location.pathname !== searchPath(),
|
||||
});
|
||||
|
||||
export const navigateToDrafts = createAction({
|
||||
name: ({ t }) => t("Drafts"),
|
||||
section: NavigationSection,
|
||||
|
||||
Reference in New Issue
Block a user