@empathyco/x-components
Version:
Empathy X Components
497 lines (212 loc) • 6.47 kB
Markdown
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
[Home](./index.md) > [@empathyco/x-components](./x-components.md) > [SearchMutations](./x-components.searchmutations.md)
## SearchMutations interface
Search store mutations.
**Signature:**
```typescript
export interface SearchMutations extends StatusMutations, QueryMutations, ConfigMutations<SearchState>
```
**Extends:** [StatusMutations](./x-components.statusmutations.md)<!-- -->, [QueryMutations](./x-components.querymutations.md)<!-- -->, [ConfigMutations](./x-components.configmutations.md)<!-- --><[SearchState](./x-components.searchstate.md)<!-- -->>
## Properties
<table><thead><tr><th>
Property
</th><th>
Modifiers
</th><th>
Type
</th><th>
Description
</th></tr></thead>
<tbody><tr><td>
[appendResults](./x-components.searchmutations.appendresults.md)
</td><td>
</td><td>
(results: Result\[\]) => void
</td><td>
Append the results to the results state.
</td></tr>
<tr><td>
[resetState](./x-components.searchmutations.resetstate.md)
</td><td>
</td><td>
() => void
</td><td>
Resets the "resettable" part of the Search state to the initial state. See the [SearchXStoreModule](./x-components.searchxstoremodule.md) for details.
</td></tr>
<tr><td>
[resetStateForReload](./x-components.searchmutations.resetstateforreload.md)
</td><td>
</td><td>
() => void
</td><td>
Resets the "resettable" part of the Search state like [SearchMutations.resetState](./x-components.searchmutations.resetstate.md) but maintains the values required to perform the search request again.
</td></tr>
<tr><td>
[setBanners](./x-components.searchmutations.setbanners.md)
</td><td>
</td><td>
(banners: Banner\[\]) => void
</td><td>
Sets the banners of the module.
</td></tr>
<tr><td>
[setDisplayTagging](./x-components.searchmutations.setdisplaytagging.md)
</td><td>
</td><td>
(DisplayTagging: TaggingRequest) => void
</td><td>
Sets the display tagging of the module.
</td></tr>
<tr><td>
[setFacets](./x-components.searchmutations.setfacets.md)
</td><td>
</td><td>
(facets: Facet\[\]) => void
</td><td>
Sets the facets of the module.
</td></tr>
<tr><td>
[setFromNoResultsWithFilters](./x-components.searchmutations.setfromnoresultswithfilters.md)
</td><td>
</td><td>
(fromNoResultsWithFilters: boolean) => void
</td><td>
Sets the `fromNoResultsWithFilters` flag value.
</td></tr>
<tr><td>
[setIsAppendResults](./x-components.searchmutations.setisappendresults.md)
</td><td>
</td><td>
(isAppendResults: boolean) => void
</td><td>
Set the `isAppendResuls` flag value.
</td></tr>
<tr><td>
[setIsNoResults](./x-components.searchmutations.setisnoresults.md)
</td><td>
</td><td>
(isNoResults: boolean) => void
</td><td>
Sets the `isNoResults` flag value.
</td></tr>
<tr><td>
[setOrigin](./x-components.searchmutations.setorigin.md)
</td><td>
</td><td>
(origin: [QueryOrigin](./x-components.queryorigin.md) \| undefined \| null) => void
</td><td>
Sets the origin of the module.
</td></tr>
<tr><td>
[setPage](./x-components.searchmutations.setpage.md)
</td><td>
</td><td>
(page: number) => void
</td><td>
Sets the page of the module.
</td></tr>
<tr><td>
[setParams](./x-components.searchmutations.setparams.md)
</td><td>
</td><td>
(params: Dictionary<unknown>) => void
</td><td>
Sets the extra params of the module.
</td></tr>
<tr><td>
[setPartialResults](./x-components.searchmutations.setpartialresults.md)
</td><td>
</td><td>
(partialResults: PartialResult\[\]) => void
</td><td>
Sets the partial results of the module.
</td></tr>
<tr><td>
[setPromoteds](./x-components.searchmutations.setpromoteds.md)
</td><td>
</td><td>
(promoteds: Promoted\[\]) => void
</td><td>
Sets the promoteds of the module.
</td></tr>
<tr><td>
[setQueryTagging](./x-components.searchmutations.setquerytagging.md)
</td><td>
</td><td>
(queryTagging: TaggingRequest) => void
</td><td>
Sets the query tagging of the module, which is used to track the query.
</td></tr>
<tr><td>
[setRedirections](./x-components.searchmutations.setredirections.md)
</td><td>
</td><td>
(redirections: Redirection\[\]) => void
</td><td>
Sets the redirection of the module.
</td></tr>
<tr><td>
[setRelatedTags](./x-components.searchmutations.setrelatedtags.md)
</td><td>
</td><td>
(relatedTags: RelatedTag\[\]) => void
</td><td>
Sets the related tags of the module.
</td></tr>
<tr><td>
[setResults](./x-components.searchmutations.setresults.md)
</td><td>
</td><td>
(results: Result\[\]) => void
</td><td>
Sets the results of the module.
</td></tr>
<tr><td>
[setSelectedFilters](./x-components.searchmutations.setselectedfilters.md)
</td><td>
</td><td>
(selectedFilters: Filter\[\]) => void
</td><td>
Sets the selected filters of the module.
</td></tr>
<tr><td>
[setSort](./x-components.searchmutations.setsort.md)
</td><td>
</td><td>
(sort: Sort) => void
</td><td>
Sets the selected sort option of the module.
</td></tr>
<tr><td>
[setSpellcheck](./x-components.searchmutations.setspellcheck.md)
</td><td>
</td><td>
(spellcheckedQuery: string) => void
</td><td>
Sets the spellcheckedQuery of the module.
</td></tr>
<tr><td>
[setStats](./x-components.searchmutations.setstats.md)
</td><td>
</td><td>
(stats: Stats) => void
</td><td>
Sets the stats of the module.
</td></tr>
<tr><td>
[setTotalResults](./x-components.searchmutations.settotalresults.md)
</td><td>
</td><td>
(totalResults: number) => void
</td><td>
Sets the total results of the module.
</td></tr>
<tr><td>
[updateResult](./x-components.searchmutations.updateresult.md)
</td><td>
</td><td>
(result: Partial<Result> & Pick<Result, 'id'>) => void
</td><td>
Updates a result with new fields.
</td></tr>
</tbody></table>