mirror of
https://github.com/jeffvli/feishin.git
synced 2026-05-08 13:00:13 +02:00
revert settings to route instead of modal
This commit is contained in:
@@ -3,7 +3,6 @@ import { useTranslation } from 'react-i18next';
|
||||
import { useNavigate } from 'react-router';
|
||||
|
||||
import { Command, CommandPalettePages } from '/@/renderer/features/search/components/command';
|
||||
import { openSettingsModal } from '/@/renderer/features/settings/utils/open-settings-modal';
|
||||
import { AppRoute } from '/@/renderer/router/routes';
|
||||
|
||||
interface GoToCommandsProps {
|
||||
@@ -37,10 +36,7 @@ export const GoToCommands = ({ handleClose, setPages, setQuery }: GoToCommandsPr
|
||||
</Command.Item>
|
||||
<Command.Item
|
||||
onSelect={() => {
|
||||
openSettingsModal();
|
||||
handleClose();
|
||||
setPages([CommandPalettePages.HOME]);
|
||||
setQuery('');
|
||||
goTo(AppRoute.SETTINGS);
|
||||
}}
|
||||
>
|
||||
{t('page.sidebar.settings', { postProcess: 'titleCase' })}
|
||||
|
||||
@@ -5,7 +5,7 @@ import { Link, useNavigate } from 'react-router';
|
||||
|
||||
import packageJson from '../../../../../package.json';
|
||||
|
||||
import { openSettingsModal } from '/@/renderer/features/settings/utils/open-settings-modal';
|
||||
import { AppRoute } from '/@/renderer/router/routes';
|
||||
import { useAppStore, useAppStoreActions } from '/@/renderer/store';
|
||||
import { DropdownMenu, MenuItemProps } from '/@/shared/components/dropdown-menu/dropdown-menu';
|
||||
import { Icon } from '/@/shared/components/icon/icon';
|
||||
@@ -184,7 +184,7 @@ export const AppMenu = () => {
|
||||
icon: 'settings',
|
||||
id: 'settings',
|
||||
label: t('page.appMenu.settings', { postProcess: 'sentenceCase' }),
|
||||
onClick: openSettingsModal,
|
||||
onClick: () => navigate(AppRoute.SETTINGS),
|
||||
type: 'item',
|
||||
},
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user