Skip to content

Commit

Permalink
Merge pull request #990 from nataliauvarova/staging
Browse files Browse the repository at this point in the history
fix design Select languages (map_search)
  • Loading branch information
nataliauvarova authored May 15, 2023
2 parents 1236c11 + caf1ce0 commit 2efd3e6
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -85,9 +85,11 @@ class Tree extends React.PureComponent {
}

this.updateNodesWithChecked(props.checked, props.filterMode);

const isAllChecked = this.constructor.isAllNodesChecked(Object.keys(this.flatNodes).length, props.checked);

this.state = {
checkAll: false,
checkAll: isAllChecked || false,
expanded:
Object.values(this.flatNodes)
.filter(item => item.expanded)
Expand Down
22 changes: 12 additions & 10 deletions src/components/Search/AdditionalFilter/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -568,16 +568,18 @@ class AdditionalFilter extends React.PureComponent {
>
<Modal.Header>{showLanguagesTreeText}</Modal.Header>
<Modal.Content scrolling>
<Languages
onChange={this.onLangsDictsChange}
languagesTree={languagesTree}
langsChecked={languages}
dictsChecked={dictionaries}
showTree={this.state.showSearchSelectLanguages}
filterMode
checkAllButtonText={checkAllButtonText}
uncheckAllButtonText={uncheckAllButtonText}
/>
<div className="filter-dictionaries">
<Languages
onChange={this.onLangsDictsChange}
languagesTree={languagesTree}
langsChecked={languages}
dictsChecked={dictionaries}
showTree={this.state.showSearchSelectLanguages}
filterMode
checkAllButtonText={checkAllButtonText}
uncheckAllButtonText={uncheckAllButtonText}
/>
</div>
</Modal.Content>
<Modal.Actions>
<Button onClick={this.onShowLangsButtonClick} className="lingvo-button-basic-black">
Expand Down

0 comments on commit 2efd3e6

Please sign in to comment.