mirror of
https://github.com/dbeaver/cloudbeaver.git
synced 2026-09-24 16:04:36 +08:00
Merge pull request #644 from dbeaver/feat/shortcuts-info
Feat/shortcuts info
This commit is contained in:
@@ -13,6 +13,10 @@ export const DATA_VIEWER_SHORTCUTS: IShortcut[] = [
|
||||
label: 'data_viewer_shortcut_start_inline_editing',
|
||||
code: ['Enter', 'Backspace'],
|
||||
},
|
||||
{
|
||||
label: 'data_viewer_shortcut_revert_inline_editor_changes',
|
||||
code: ['Escape'],
|
||||
},
|
||||
{
|
||||
label: 'data_viewer_shortcut_add_new_row',
|
||||
code: ['Alt + Insert'],
|
||||
@@ -25,10 +29,6 @@ export const DATA_VIEWER_SHORTCUTS: IShortcut[] = [
|
||||
label: 'data_viewer_shortcut_delete_row',
|
||||
code: ['Delete'],
|
||||
},
|
||||
{
|
||||
label: 'data_viewer_shortcut_revert_inline_editor_changes',
|
||||
code: ['Escape'],
|
||||
},
|
||||
{
|
||||
label: 'data_viewer_shortcut_past_value',
|
||||
code: ['Ctrl + V'],
|
||||
@@ -60,4 +60,11 @@ export const SQL_EDITOR_SHORTCUTS: IShortcut[] = [
|
||||
label: 'sql_editor_shortcut_open_editor_in_new_tab',
|
||||
code: ['Alt + T'],
|
||||
},
|
||||
];
|
||||
|
||||
export const NAVIGATION_TREE_SHORTCUTS: IShortcut[] = [
|
||||
{
|
||||
label: 'navigation_tree_shortcut_enable_filter',
|
||||
code: ['Ctrl + F'],
|
||||
},
|
||||
];
|
||||
@@ -14,19 +14,16 @@ import { useTranslate } from '@cloudbeaver/core-localization';
|
||||
import { useStyles } from '@cloudbeaver/core-theming';
|
||||
|
||||
import { Shortcut } from './Shortcut';
|
||||
import { DATA_VIEWER_SHORTCUTS, SQL_EDITOR_SHORTCUTS } from './SHORTCUTS_DATA';
|
||||
import { DATA_VIEWER_SHORTCUTS, NAVIGATION_TREE_SHORTCUTS, SQL_EDITOR_SHORTCUTS } from './SHORTCUTS_DATA';
|
||||
|
||||
|
||||
const style = css`
|
||||
CommonDialogWrapper {
|
||||
max-width: 1100px;
|
||||
}
|
||||
Button {
|
||||
margin-left: auto;
|
||||
}
|
||||
Container {
|
||||
composes: theme-typography--body2 from global;
|
||||
gap: 16px;
|
||||
gap: 32px;
|
||||
}
|
||||
Group {
|
||||
gap: 16px;
|
||||
@@ -34,6 +31,9 @@ const style = css`
|
||||
GroupTitle, Group {
|
||||
padding: 0 !important;
|
||||
}
|
||||
GroupTitle {
|
||||
font-weight: bold;
|
||||
}
|
||||
`;
|
||||
|
||||
export const ShortcutsDialog: DialogComponent<null> = function ShortcutsDialog({
|
||||
@@ -54,7 +54,7 @@ export const ShortcutsDialog: DialogComponent<null> = function ShortcutsDialog({
|
||||
onReject={rejectDialog}
|
||||
>
|
||||
<Container wrap overflow>
|
||||
<Group medium overflow>
|
||||
<Group overflow>
|
||||
<GroupTitle>
|
||||
<Link href='https://cloudbeaver.io/docs/Data-editor/' target='_blank' wrapper indicator>
|
||||
Data Viewer
|
||||
@@ -62,7 +62,7 @@ export const ShortcutsDialog: DialogComponent<null> = function ShortcutsDialog({
|
||||
</GroupTitle>
|
||||
{DATA_VIEWER_SHORTCUTS.map(shortcut => <Shortcut key={shortcut.label} shortcut={shortcut} />)}
|
||||
</Group>
|
||||
<Group medium overflow>
|
||||
<Group overflow>
|
||||
<GroupTitle>
|
||||
<Link href='https://cloudbeaver.io/docs/SQL-Editor/' target='_blank' wrapper indicator>
|
||||
SQL Editor
|
||||
@@ -70,6 +70,14 @@ export const ShortcutsDialog: DialogComponent<null> = function ShortcutsDialog({
|
||||
</GroupTitle>
|
||||
{SQL_EDITOR_SHORTCUTS.map(shortcut => <Shortcut key={shortcut.label} shortcut={shortcut} />)}
|
||||
</Group>
|
||||
<Group overflow>
|
||||
<GroupTitle>
|
||||
<Link href='https://cloudbeaver.io/docs/Database-navigator/' target='_blank' wrapper indicator>
|
||||
Navigation Tree
|
||||
</Link>
|
||||
</GroupTitle>
|
||||
{NAVIGATION_TREE_SHORTCUTS.map(shortcut => <Shortcut key={shortcut.label} shortcut={shortcut} />)}
|
||||
</Group>
|
||||
</Container>
|
||||
</CommonDialogWrapper>
|
||||
);
|
||||
|
||||
@@ -14,4 +14,6 @@ export default [
|
||||
['sql_editor_shortcut_execute_script', 'Execute script'],
|
||||
['sql_editor_shortcut_show_execution_plan', 'Show Execution plan'],
|
||||
['sql_editor_shortcut_open_editor_in_new_tab', 'Open SQL Editor in the separate browser Tab'],
|
||||
|
||||
['navigation_tree_shortcut_enable_filter', 'Enable filtering'],
|
||||
];
|
||||
|
||||
@@ -14,4 +14,6 @@ export default [
|
||||
['sql_editor_shortcut_execute_script', 'Execute script'],
|
||||
['sql_editor_shortcut_show_execution_plan', 'Show Execution plan'],
|
||||
['sql_editor_shortcut_open_editor_in_new_tab', 'Open SQL Editor in the separate browser Tab'],
|
||||
|
||||
['navigation_tree_shortcut_enable_filter', 'Enable filtering'],
|
||||
];
|
||||
|
||||
@@ -14,4 +14,6 @@ export default [
|
||||
['sql_editor_shortcut_execute_script', 'Выполнить скрипт'],
|
||||
['sql_editor_shortcut_show_execution_plan', 'Показать план выполнения'],
|
||||
['sql_editor_shortcut_open_editor_in_new_tab', 'Открыть SQL редактор в новой бразуерной вкладке'],
|
||||
|
||||
['navigation_tree_shortcut_enable_filter', 'Включить фильтрацию'],
|
||||
];
|
||||
|
||||
@@ -14,4 +14,6 @@ export default [
|
||||
['sql_editor_shortcut_execute_script', 'Execute script'],
|
||||
['sql_editor_shortcut_show_execution_plan', 'Show Execution plan'],
|
||||
['sql_editor_shortcut_open_editor_in_new_tab', 'Open SQL Editor in the separate browser Tab'],
|
||||
|
||||
['navigation_tree_shortcut_enable_filter', 'Enable filtering'],
|
||||
];
|
||||
|
||||
Reference in New Issue
Block a user