Skip to content

Commit

Permalink
Merge pull request #148 from NDLANO/fix/label-position-expand-up
Browse files Browse the repository at this point in the history
fix: only use expand-up when label can expand
  • Loading branch information
otacke authored Apr 28, 2024
2 parents 737c4d2 + 2f520c0 commit e9a185d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion scripts/components/Interactions/NavigationButtonLabel.js
Original file line number Diff line number Diff line change
Expand Up @@ -328,7 +328,7 @@ export default class NavigationButtonLabel extends React.Component {
const isExpanded = this.state.isExpanded ? 'is-expanded' : '';
const canExpand = this.state.expandable ? 'can-expand' : '';
const isMultline = (this.state.divHeight !== '1.5em') ? 'is-multiline' : '';
const expandDirection = this.state.expandDirection ?
const expandDirection = this.state.expandDirection && canExpand ?
'expand-' + this.state.expandDirection :
'';
const alignment = this.state.alignment || this.props.labelPos;
Expand Down

0 comments on commit e9a185d

Please sign in to comment.