mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-16 12:50:38 +00:00
chrone: sperate client and server to different repos.
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
import React from 'react';
|
||||
import { DialogContent } from 'components';
|
||||
import ShortcutsTable from '../../KeyboardShortcuts/ShortcutsTable';
|
||||
import KeyboardShortcutsFooter from './KeyboardShortcutsFooter';
|
||||
|
||||
import 'style/pages/keyboardShortcuts/KeyboardShortcutDialog.scss';
|
||||
|
||||
export default function KeyboardShortcutsDialogContent() {
|
||||
return (
|
||||
<DialogContent name={'keyboard-shortcuts'}>
|
||||
<ShortcutsTable />
|
||||
<KeyboardShortcutsFooter />
|
||||
</DialogContent>
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,25 @@
|
||||
import React from 'react';
|
||||
import { Button, Intent } from '@blueprintjs/core';
|
||||
import { FormattedMessage as T } from 'components';
|
||||
|
||||
import withDialogActions from 'containers/Dialog/withDialogActions';
|
||||
import { compose } from 'utils';
|
||||
|
||||
function KeyboardShortcutsFooter({
|
||||
// #withDialogActions
|
||||
closeDialog,
|
||||
}) {
|
||||
const handleClose = () => {
|
||||
closeDialog('keyboard-shortcuts');
|
||||
};
|
||||
|
||||
return (
|
||||
<div className={'dialog--keyboard-shortcuts__footer'}>
|
||||
<Button intent={Intent.PRIMARY} onClick={handleClose} small={true}>
|
||||
<T id={'oK_'} />
|
||||
</Button>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
export default compose(withDialogActions)(KeyboardShortcutsFooter);
|
||||
30
src/containers/Dialogs/keyboardShortcutsDialog/index.js
Normal file
30
src/containers/Dialogs/keyboardShortcutsDialog/index.js
Normal file
@@ -0,0 +1,30 @@
|
||||
import React, { lazy } from 'react';
|
||||
import { FormattedMessage as T } from 'components';
|
||||
import intl from 'react-intl-universal';
|
||||
import { Dialog, DialogSuspense } from 'components';
|
||||
import withDialogRedux from 'components/DialogReduxConnect';
|
||||
import { compose } from 'utils';
|
||||
|
||||
const KeyboardShortcutsContent = lazy(() =>
|
||||
import('./KeyboardShortcutsDialogContent'),
|
||||
);
|
||||
|
||||
/**
|
||||
* Keyboard shortcuts dialog.
|
||||
*/
|
||||
function KeyboardShortcutsDialog({ dialogName, isOpen }) {
|
||||
return (
|
||||
<Dialog
|
||||
name={dialogName}
|
||||
isOpen={isOpen}
|
||||
className={'dialog--keyboard-shortcuts'}
|
||||
title={<T id={'keyboard_shortcuts'} canEscapeKeyClose={true} />}
|
||||
>
|
||||
<DialogSuspense>
|
||||
<KeyboardShortcutsContent />
|
||||
</DialogSuspense>
|
||||
</Dialog>
|
||||
);
|
||||
}
|
||||
|
||||
export default compose(withDialogRedux())(KeyboardShortcutsDialog);
|
||||
Reference in New Issue
Block a user