- Add icanhazstring/composer-unused as dev dependency for dependency hygiene checks - Add German documentation (docs/) covering architecture, conventions, workflows, and developer checklists - Add API layer (ApiAuth, ApiBootstrap, ApiResponse), audit, scheduler, custom fields, and SSO services - Add Microsoft OIDC SSO, API token management, and user lifecycle features - Add swagger-ui vendor integration and OpenAPI spec - Add production Docker setup and bin/ scripts - Update composer dependencies, config, templates, and frontend assets throughout Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
66 lines
1.5 KiB
PHP
66 lines
1.5 KiB
PHP
<?php
|
|
|
|
namespace MintyPHP\Service\Ui;
|
|
|
|
class HotkeyService
|
|
{
|
|
/**
|
|
* Canonical hotkey list used by UI pages and search.
|
|
*
|
|
* @return array<int, array{action_key: string, mac: string, win: string}>
|
|
*/
|
|
public static function list(): array
|
|
{
|
|
return [
|
|
[
|
|
'action_key' => 'Open search',
|
|
'mac' => 'Cmd + K',
|
|
'win' => 'Ctrl + K',
|
|
],
|
|
[
|
|
'action_key' => 'Toggle sidebar',
|
|
'mac' => 'Cmd + B',
|
|
'win' => 'Ctrl + B',
|
|
],
|
|
[
|
|
'action_key' => 'Switch sidebar section',
|
|
'mac' => 'Cmd + 1 ... 0',
|
|
'win' => 'Ctrl + 1 ... 0',
|
|
],
|
|
[
|
|
'action_key' => 'Back',
|
|
'mac' => 'Alt + Left',
|
|
'win' => 'Alt + Left',
|
|
],
|
|
[
|
|
'action_key' => 'Forward',
|
|
'mac' => 'Alt + Right',
|
|
'win' => 'Alt + Right',
|
|
],
|
|
];
|
|
}
|
|
|
|
/**
|
|
* Keywords that should trigger hotkey search results.
|
|
*
|
|
* @return string[]
|
|
*/
|
|
public static function searchKeywords(): array
|
|
{
|
|
return [
|
|
'shortcut',
|
|
'shortcuts',
|
|
'hotkey',
|
|
'hotkeys',
|
|
'keyboard',
|
|
'key',
|
|
'ctrl',
|
|
'cmd',
|
|
'command',
|
|
'tastenkurzel',
|
|
'tastenkuerzel',
|
|
'taste',
|
|
];
|
|
}
|
|
}
|