Skip to content
Snippets Groups Projects
Select Git revision
  • 378652cf289f27cc6683cdb7180a7ceaee71fc91
  • master default protected
  • multiprocessing
  • experiment/clara
  • experiment/spec2B-poc
  • experiment/qivalio-poc
  • experiment/ertms
  • MAY-2023
  • FEB-2023
  • EGC-2023
  • 0.2.1
  • v0.2.0
  • v0.1.2
13 results

prepare_work_data.py

Blame
  • WindowTopMenu.js 991 B
    import { compose } from 'redux';
    import { connect } from 'react-redux';
    import { withTranslation } from 'react-i18next';
    import { withPlugins } from '../extend/withPlugins';
    import * as actions from '../state/actions';
    import { WindowTopMenu } from '../components/WindowTopMenu';
    import { getConfig, getContainerId } from '../state/selectors';
    
    /**
     * mapStateToProps - to hook up connect
     * @memberof WindowTopMenu
     * @private
     */
    const mapStateToProps = state => ({
      containerId: getContainerId(state),
      showThumbnailNavigationSettings: getConfig(state).thumbnailNavigation.displaySettings,
    });
    
    /**
     * mapStateToProps - used to hook up connect to state
     * @memberof WindowTopMenu
     * @private
     */
    const mapDispatchToProps = dispatch => ({
      toggleDraggingEnabled: () => dispatch(actions.toggleDraggingEnabled()),
    });
    
    const enhance = compose(
      withTranslation(),
      connect(mapStateToProps, mapDispatchToProps),
      withPlugins('WindowTopMenu'),
    );
    
    export default enhance(WindowTopMenu);