mirror of
https://github.com/mountain-loop/yaak.git
synced 2026-04-17 06:19:41 +02:00
Fix window stoplights
This commit is contained in:
@@ -1,6 +1,9 @@
|
||||
import { invoke } from '@tauri-apps/api/core';
|
||||
import { open } from '@tauri-apps/plugin-shell';
|
||||
import { useRef } from 'react';
|
||||
import { useActiveWorkspaceId } from '../hooks/useActiveWorkspaceId';
|
||||
import { useAppInfo } from '../hooks/useAppInfo';
|
||||
import { useAppRoutes } from '../hooks/useAppRoutes';
|
||||
import { useCheckForUpdates } from '../hooks/useCheckForUpdates';
|
||||
import { useExportData } from '../hooks/useExportData';
|
||||
import { useImportData } from '../hooks/useImportData';
|
||||
@@ -20,6 +23,8 @@ export function SettingsDropdown() {
|
||||
const dropdownRef = useRef<DropdownRef>(null);
|
||||
const dialog = useDialog();
|
||||
const checkForUpdates = useCheckForUpdates();
|
||||
const routes = useAppRoutes();
|
||||
const workspaceId = useActiveWorkspaceId();
|
||||
|
||||
const showSettings = () => {
|
||||
dialog.show({
|
||||
@@ -58,6 +63,20 @@ export function SettingsDropdown() {
|
||||
});
|
||||
},
|
||||
},
|
||||
{
|
||||
key: 'foo',
|
||||
label: 'Foo',
|
||||
hotKeyAction: 'hotkeys.showHelp',
|
||||
leftSlot: <Icon icon="keyboard" />,
|
||||
onSelect: async () => {
|
||||
if (!workspaceId) return;
|
||||
await invoke('cmd_new_nested_window', {
|
||||
url: routes.paths.workspaceSettings({ workspaceId }),
|
||||
label: 'settings',
|
||||
title: 'Yaak Settings',
|
||||
});
|
||||
},
|
||||
},
|
||||
{
|
||||
key: 'import-data',
|
||||
label: 'Import Data',
|
||||
|
||||
Reference in New Issue
Block a user