feat: shortcuts
This commit is contained in:
@ -85,6 +85,15 @@ listen('launch-end', () => {
|
||||
getCurrentWindow().setFocus();
|
||||
});
|
||||
|
||||
const createShortcut = async () => {
|
||||
const current = prf.current;
|
||||
if (current !== null) {
|
||||
await invoke('create_shortcut', {
|
||||
profileMeta: current.meta,
|
||||
});
|
||||
}
|
||||
};
|
||||
|
||||
const menuItems = [
|
||||
{
|
||||
label: 'Refresh and start',
|
||||
@ -96,6 +105,11 @@ const menuItems = [
|
||||
icon: 'pi pi-exclamation-circle',
|
||||
command: async () => await startline(true, false),
|
||||
},
|
||||
{
|
||||
label: 'Create shortcut',
|
||||
icon: 'pi pi-link',
|
||||
command: createShortcut,
|
||||
},
|
||||
];
|
||||
const menu = ref();
|
||||
|
||||
|
Reference in New Issue
Block a user