diff --git a/components/layout/navigation-rail.tsx b/components/layout/navigation-rail.tsx index 5e78e395..e72f166a 100644 --- a/components/layout/navigation-rail.tsx +++ b/components/layout/navigation-rail.tsx @@ -20,6 +20,7 @@ import { useAccountStore } from "@/stores/account-store"; import { getInitials } from "@/lib/account-utils"; import { cn, formatFileSize } from "@/lib/utils"; import { PluginSlot } from "@/components/plugins/plugin-slot"; +import { KeyboardShortcutsModal } from "@/components/keyboard-shortcuts-modal"; interface NavItem { id: string; @@ -182,6 +183,7 @@ export function NavigationRail({ const logoutBtnRef = useRef(null); const logoutPopoverRef = useRef(null); const [logoutPopoverStyle, setLogoutPopoverStyle] = useState({}); + const [showShortcutsModal, setShowShortcutsModal] = useState(false); const updateLogoutPosition = useCallback(() => { if (!logoutBtnRef.current) return; @@ -549,6 +551,22 @@ export function NavigationRail({ )} + {!onShowShortcuts && ( + <> + + setShowShortcutsModal(false)} + /> + + )} {quota && quota.total > 0 && (
@@ -556,26 +574,12 @@ export function NavigationRail({
)} - {isPushConnected != null && ( - - - - )} - {onLogout && showRailAccountList && accounts.length > 0 && ( <> -
+
{/* Account circles */} -
+
{accounts.map((account) => { const isActive = account.id === activeAccountId; const initials = getInitials(account.displayName || account.label, account.email || account.username); @@ -586,7 +590,7 @@ export function NavigationRail({ if (!isActive) switchAccount(account.id); }} className={cn( - "relative flex items-center justify-center w-9 h-9 rounded-full text-white text-xs font-medium transition-all flex-shrink-0", + "relative flex items-center justify-center w-8 h-8 rounded-full text-white text-[11px] font-medium transition-all flex-shrink-0", isActive ? "ring-2 ring-primary ring-offset-2 ring-offset-background" : "opacity-70 hover:opacity-100"