From b19db0bbea168f757fe1f6c7ff254128373cc593 Mon Sep 17 00:00:00 2001 From: Maze Winther Date: Fri, 18 Jul 2025 11:26:49 +0200 Subject: [PATCH] cleanup --- apps/web/src/app/globals.css | 22 ------------------- .../components/keyboard-shortcuts-help.tsx | 18 +++++++++++++-- 2 files changed, 16 insertions(+), 24 deletions(-) diff --git a/apps/web/src/app/globals.css b/apps/web/src/app/globals.css index bc9638ef..2f7158cc 100644 --- a/apps/web/src/app/globals.css +++ b/apps/web/src/app/globals.css @@ -86,25 +86,3 @@ overscroll-behavior-x: contain; } } - -.shortcut-key { - @apply inline-flex; - @apply font-sans; - @apply text-xs; - @apply rounded; - @apply px-2; - @apply min-w-[1.5rem]; - @apply min-h-[1.5rem]; - @apply leading-none; - @apply items-center; - @apply justify-center; - @apply shadow-sm; - @apply border; - - background-color: rgba(0, 0, 0, 0.2); - border-color: rgba(255, 255, 255, 0.1); - - &:not(:last-child) { - @apply mr-1; - } -} diff --git a/apps/web/src/components/keyboard-shortcuts-help.tsx b/apps/web/src/components/keyboard-shortcuts-help.tsx index a33ba666..a48b3c21 100644 --- a/apps/web/src/components/keyboard-shortcuts-help.tsx +++ b/apps/web/src/components/keyboard-shortcuts-help.tsx @@ -56,9 +56,9 @@ const ShortcutItem = ({ shortcut }: { shortcut: any }) => {
{key.split("+").map((keyPart: string, partIndex: number) => ( - + {getKeyWithModifier(keyPart)} - + ))}
{index < displayKeys.length - 1 && ( @@ -119,3 +119,17 @@ export const KeyboardShortcutsHelp = () => { ); }; + +function ShortcutKey({ children }: { children: React.ReactNode }) { + return ( + + {children} + + ); +};