Skip to content

Commit

Permalink
PATCH: Don't pass user down to Drawer & UserDropDown
Browse files Browse the repository at this point in the history
  • Loading branch information
grebaldi committed May 30, 2024
1 parent 44255f8 commit eac76c0
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 30 deletions.
17 changes: 2 additions & 15 deletions packages/neos-ui/src/Containers/App.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import style from './style.module.css';

import FlashMessages from './FlashMessages/index';

const App = ({globalRegistry, menu, user, isFullScreen, leftSidebarIsHidden, rightSidebarIsHidden}) => {
const App = ({globalRegistry, menu, isFullScreen, leftSidebarIsHidden, rightSidebarIsHidden}) => {
const containerRegistry = globalRegistry.get('containers');

const Modals = containerRegistry.get('Modals');
Expand Down Expand Up @@ -34,7 +34,7 @@ const App = ({globalRegistry, menu, user, isFullScreen, leftSidebarIsHidden, rig
<PrimaryToolbar/>
<SecondaryToolbar/>
<ContentCanvas/>
<Drawer menuData={menu} user={user}/>
<Drawer menuData={menu}/>
<LeftSideBar/>
<RightSideBar/>
</div>
Expand All @@ -61,19 +61,6 @@ App.propTypes = {
)
})
).isRequired,
user: PropTypes.shape({
name: PropTypes.shape({
title: PropTypes.string,
firstName: PropTypes.string,
middleName: PropTypes.string,
lastName: PropTypes.string,
otherName: PropTypes.string,
fullName: PropTypes.string
}).isRequired,
preferences: PropTypes.shape({
interfaceLanguage: PropTypes.string
}).isRequired
}).isRequired,
isFullScreen: PropTypes.bool.isRequired,
leftSidebarIsHidden: PropTypes.bool.isRequired,
rightSidebarIsHidden: PropTypes.bool.isRequired
Expand Down
17 changes: 2 additions & 15 deletions packages/neos-ui/src/Containers/Root.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ library.add(fab, fas, far);

class Root extends PureComponent {
render() {
const {store, globalRegistry, configuration, menu, user, routes} = this.props;
const {store, globalRegistry, configuration, menu, routes} = this.props;

const containerRegistry = globalRegistry.get('containers');
const App = containerRegistry.get('App');
Expand All @@ -36,7 +36,7 @@ class Root extends PureComponent {
configuration={configuration}
routes={routes}
>
<App globalRegistry={globalRegistry} menu={menu} user={user}/>
<App globalRegistry={globalRegistry} menu={menu}/>
</Neos>
</DndProvider>
</Provider>
Expand Down Expand Up @@ -69,19 +69,6 @@ Root.propTypes = {
)
})
).isRequired,
user: PropTypes.shape({
name: PropTypes.shape({
title: PropTypes.string,
firstName: PropTypes.string,
middleName: PropTypes.string,
lastName: PropTypes.string,
otherName: PropTypes.string,
fullName: PropTypes.string
}).isRequired,
preferences: PropTypes.shape({
interfaceLanguage: PropTypes.string
}).isRequired
}).isRequired,
routes: PropTypes.object.isRequired
};

Expand Down

0 comments on commit eac76c0

Please sign in to comment.