A fully open source & end-to-end encrypted note taking alternative to Evernote.
TypeScript asp-net-coredotnet-coreelectronfosshacktoberfestnote-managmentnote-takingnote-taking-appnotebooknotesnotes-appopen-sourceopensourceprivacyproductivityreactreact-nativereactjsself-hosted
ui: use symbols for shortcut keys on macOS
Abdullah Atta8be4fea7a3f3
diff --git a/packages/ui/src/components/menu/menu-button.tsx b/packages/ui/src/components/menu/menu-button.tsxindex 04a03d2e7..d60c9cb84 100644--- a/packages/ui/src/components/menu/menu-button.tsx+++ b/packages/ui/src/components/menu/menu-button.tsx@@ -141,10 +141,16 @@ export function MenuButton(props: MenuButtonProps) {const platform = getPlatform();function translateModifier(modifier: string) {if (platform === "Android" || platform === "iOS") return "";+ const isMacOS = platform === "macOS";const parts = modifier.split("-");return parts- .map((p) => (p === "Mod" ? (platform === "macOS" ? "Cmd" : "Ctrl") : p))- .join("+");+ .map((p) => {+ if (isMacOS) {+ return p === "Mod" ? "⌘" : p === "Alt" ? "⌥" : p === "Shift" ? "⇧" : p;+ }+ return p === "Mod" ? "Ctrl" : p;+ })+ .join(isMacOS ? "" : "+");}function getPlatform() {