merge master
[arvados-workbench2.git] / src / views / main-panel / main-panel.tsx
1 // Copyright (C) The Arvados Authors. All rights reserved.
2 //
3 // SPDX-License-Identifier: AGPL-3.0
4
5 import { RootState } from '~/store/store';
6 import { connect } from 'react-redux';
7 import { MainPanelRoot, MainPanelRootDataProps } from '~/views/main-panel/main-panel-root';
8 import { isSystemWorking } from '~/store/progress-indicator/progress-indicator-reducer';
9 import { isWorkbenchLoading } from '~/store/workbench/workbench-actions';
10
11 const mapStateToProps = (state: RootState): MainPanelRootDataProps => {
12     return {
13         user: state.auth.user,
14         working: isSystemWorking(state.progressIndicator),
15         loading: isWorkbenchLoading(state),
16         buildInfo: state.appInfo.buildInfo
17     };
18 };
19
20 const mapDispatchToProps = null;
21
22 export const MainPanel = connect(mapStateToProps, mapDispatchToProps)(MainPanelRoot);