Skip to content

Commit

Permalink
Fix for SideNav not collapsing when toggling the menu button
Browse files Browse the repository at this point in the history
The `expanded` prop of the `SideNav` component was incorrectly set
as an object instead of a boolean, preventing the nav from being
collapsed. Fix the state update so it's providing a boolean as
expected.
  • Loading branch information
AlanGreene authored and tekton-robot committed Apr 22, 2021
1 parent 787dbeb commit f16fa82
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ class LabelFilter extends Component {
)}
<Form onSubmit={this.handleAddFilter} autoComplete="on">
<Search
placeHolderText={searchDescription}
placeholder={searchDescription}
labelText={searchDescription}
onChange={this.handleChange}
value={currentFilterValue}
Expand Down
6 changes: 3 additions & 3 deletions src/containers/App/App.js
Original file line number Diff line number Diff line change
Expand Up @@ -218,9 +218,9 @@ export function App({
isSideNavExpanded={isSideNavExpanded}
logoutButton={logoutButton}
onHeaderMenuButtonClick={() => {
setIsSideNavExpanded(prevIsSideNavExpanded => ({
isSideNavExpanded: !prevIsSideNavExpanded
}));
setIsSideNavExpanded(
prevIsSideNavExpanded => !prevIsSideNavExpanded
);
}}
/>
<Route path={paths.byNamespace({ path: '/*' })}>
Expand Down

0 comments on commit f16fa82

Please sign in to comment.