[ADF-3401] Search filters - fix facet update (#4249)

* [ADF-3401] refactoring - different way to call the facet parsers

* [ADF-3401] fix duplicate search call

* [ADF-3401] add new fields and buckets from the response

- If a facet is already displayed, just update the bucket count, else add the new facet to the responseFields
- this way any existing filters are preserved, the collapsed state is preserved, facet selection is preserved

* [ADF-3401] reset & clear all selections buttons

* [ADF-3401] delete facets that are not in the response

- for better UX, prevent deletion of items from the category where there is a selected item
- clean-up reset buttons

* [ADF-3401] apply filters to the newly created items

* [ADF-3401] update tests

* [ADF-3401] fix after rebase

* [ADF-3401] Code refactoring

* [ADF-3401] show count value inside tooltip

* [ADF-3401] translatable strings

* [ADF-3401] move 'Clear all selections' button to search-chip-list

* [ADF-3401] option to configure having a reset button for filters

* [ADF-3401] code cleanup and improvements after review

* Update lib/content-services/search/components/search-filter/search-filter.component.ts

Co-Authored-By: suzanadirla <dirla.silvia.suzana@gmail.com>

* [ADF-3401] Better namings

* fix failing e2e tests on search radio

* [ADF-3401] add documentation for search resetButton
This commit is contained in:
Suzana Dirla
2019-03-05 16:08:38 +02:00
committed by Eugenio Romano
parent 933a7256a3
commit fb11cc879d
14 changed files with 212 additions and 85 deletions

View File

@@ -102,6 +102,7 @@
}
]
},
"resetButton": true,
"filterQueries": [
{ "query": "TYPE:'cm:folder' OR TYPE:'cm:content'" },
{ "query": "NOT cm:creator:System" }

View File

@@ -1,5 +1,5 @@
<div class="adf-search-results__facets">
<adf-search-chip-list [searchFilter]="searchFilter"></adf-search-chip-list>
<adf-search-chip-list [searchFilter]="searchFilter" [clearAll]="true"></adf-search-chip-list>
</div>
<div class="adf-search-results">