mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-17 05:10:31 +00:00
chrone: sperate client and server to different repos.
This commit is contained in:
51
src/components/Preferences/PreferencesTopbar.js
Normal file
51
src/components/Preferences/PreferencesTopbar.js
Normal file
@@ -0,0 +1,51 @@
|
||||
import React from 'react';
|
||||
import { Route, Switch } from 'react-router-dom';
|
||||
import classNames from 'classnames';
|
||||
import { CLASSES } from 'common/classes';
|
||||
|
||||
import DashboardTopbarUser from 'components/Dashboard/TopbarUser';
|
||||
import UsersActions from 'containers/Preferences/Users/UsersActions';
|
||||
import CurrenciesActions from 'containers/Preferences/Currencies/CurrenciesActions';
|
||||
import withDashboard from 'containers/Dashboard/withDashboard';
|
||||
|
||||
import { compose } from 'utils';
|
||||
|
||||
import 'style/pages/Preferences/Topbar.scss';
|
||||
|
||||
/**
|
||||
* Preferences topbar.
|
||||
*/
|
||||
function PreferencesTopbar({ preferencesPageTitle }) {
|
||||
return (
|
||||
<div
|
||||
className={classNames(
|
||||
CLASSES.PREFERENCES_PAGE_TOPBAR,
|
||||
CLASSES.PREFERENCES_TOPBAR,
|
||||
)}
|
||||
>
|
||||
<div class="preferences-topbar__title">
|
||||
<h2>{preferencesPageTitle}</h2>
|
||||
</div>
|
||||
<div class="preferences-topbar__actions">
|
||||
<Route pathname="/preferences">
|
||||
<Switch>
|
||||
<Route exact path={'/preferences/users'} component={UsersActions} />
|
||||
<Route
|
||||
exact
|
||||
path={'/preferences/currencies'}
|
||||
component={CurrenciesActions}
|
||||
/>
|
||||
</Switch>
|
||||
</Route>
|
||||
</div>
|
||||
|
||||
<div class="preferences-topbar__user">
|
||||
<DashboardTopbarUser />
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
export default compose(
|
||||
withDashboard(({ preferencesPageTitle }) => ({ preferencesPageTitle })),
|
||||
)(PreferencesTopbar);
|
||||
Reference in New Issue
Block a user