Merge branch 'develop' of https://github.com/TriliumNext/Notes into develop

This commit is contained in:
Adorian Doran 2025-02-03 01:09:04 +02:00
commit 7d81c65e8e
3 changed files with 0 additions and 32 deletions

View File

@ -4,7 +4,6 @@ import noteTooltipService from "./services/note_tooltip.js";
import bundleService from "./services/bundle.js"; import bundleService from "./services/bundle.js";
import toastService from "./services/toast.js"; import toastService from "./services/toast.js";
import noteAutocompleteService from "./services/note_autocomplete.js"; import noteAutocompleteService from "./services/note_autocomplete.js";
import macInit from "./services/mac_init.js";
import electronContextMenu from "./menus/electron_context_menu.js"; import electronContextMenu from "./menus/electron_context_menu.js";
import glob from "./services/glob.js"; import glob from "./services/glob.js";
import { t } from "./services/i18n.js"; import { t } from "./services/i18n.js";
@ -35,8 +34,6 @@ if (utils.isElectron()) {
initOnElectron(); initOnElectron();
} }
macInit.init();
noteTooltipService.setupGlobalTooltip(); noteTooltipService.setupGlobalTooltip();
noteAutocompleteService.init(); noteAutocompleteService.init();

View File

@ -1,26 +0,0 @@
/**
* Mac specific initialization
*/
import utils from "./utils.js";
import shortcutService from "./shortcuts.js";
function init() {
if (utils.isElectron() && utils.isMac()) {
shortcutService.bindGlobalShortcut("meta+c", () => exec("copy"));
shortcutService.bindGlobalShortcut("meta+v", () => exec("paste"));
shortcutService.bindGlobalShortcut("meta+x", () => exec("cut"));
shortcutService.bindGlobalShortcut("meta+a", () => exec("selectAll"));
shortcutService.bindGlobalShortcut("meta+z", () => exec("undo"));
shortcutService.bindGlobalShortcut("meta+y", () => exec("redo"));
}
}
function exec(cmd: string) {
document.execCommand(cmd);
return false;
}
export default {
init
};

View File

@ -1,9 +1,6 @@
import utils from "./services/utils.js"; import utils from "./services/utils.js";
import macInit from "./services/mac_init.js";
import ko from "knockout"; import ko from "knockout";
macInit.init();
// TriliumNextTODO: properly make use of below types // TriliumNextTODO: properly make use of below types
// type SetupModelSetupType = "new-document" | "sync-from-desktop" | "sync-from-server" | ""; // type SetupModelSetupType = "new-document" | "sync-from-desktop" | "sync-from-server" | "";
// type SetupModelStep = "sync-in-progress" | "setup-type" | "new-document-in-progress" | "sync-from-desktop"; // type SetupModelStep = "sync-in-progress" | "setup-type" | "new-document-in-progress" | "sync-from-desktop";