klg-asutk-app/components/KeyboardShortcutsHelp.tsx
Yuriy 0150aba4f5 Consolidation: KLG ASUTK + PAPA integration
- Unify API: lib/api.ts uses /api/v1, inbox uses /api/inbox (rewrites)
- Remove localhost refs: openapi, inbox page
- Add rewrites: /api/inbox|tmc -> inbox-server, /api/v1 -> FastAPI
- Add stub routes: knowledge/insights, recommendations, search, log-error
- Transfer from PAPA: prompts (inspection, tmc), scripts, supabase, data/tmc-requests
- Fix inbox-server: ORDER BY created_at, package.json
- Remove redundant app/api/inbox/files route (rewrites handle it)
- knowledge/ in gitignore (large PDFs)

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-08 17:18:31 +03:00

61 lines
1.8 KiB
TypeScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

/**
* Компонент для отображения подсказок по горячим клавишам
*/
'use client';
export default function KeyboardShortcutsHelp() {
const shortcuts: Array<{ keys: string; description: string }> = [
{ keys: 'Ctrl+K', description: 'Глобальный поиск' },
{ keys: 'Ctrl+N', description: 'Создать новую запись' },
{ keys: 'Ctrl+S', description: 'Сохранить форму' },
{ keys: 'Esc', description: 'Закрыть модальное окно' },
];
return (
<div
style={{
position: 'fixed',
bottom: '20px',
right: '20px',
backgroundColor: 'white',
padding: '16px',
borderRadius: '8px',
boxShadow: '0 4px 6px rgba(0,0,0,0.1)',
zIndex: 1000,
maxWidth: '300px',
}}
>
<h3 style={{ fontSize: '14px', fontWeight: 'bold', marginBottom: '12px' }}>
Горячие клавиши
</h3>
<div style={{ display: 'flex', flexDirection: 'column', gap: '8px' }}>
{shortcuts.map((shortcut, index) => (
<div
key={index}
style={{
display: 'flex',
justifyContent: 'space-between',
alignItems: 'center',
fontSize: '12px',
}}
>
<span style={{ color: '#666' }}>{shortcut.description}</span>
<kbd
style={{
padding: '4px 8px',
backgroundColor: '#f5f5f5',
border: '1px solid #ccc',
borderRadius: '4px',
fontFamily: 'monospace',
fontSize: '11px',
}}
>
{shortcut.keys}
</kbd>
</div>
))}
</div>
</div>
);
}