@empathyco/x-components
Version:
Empathy X Components
288 lines (124 loc) • 4.28 kB
Markdown
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
[Home](./index.md) > [@empathyco/x-components](./x-components.md) > [FacetsMutations](./x-components.facetsmutations.md)
## FacetsMutations interface
Facets store mutations.
**Signature:**
```typescript
export interface FacetsMutations extends StatusMutations, QueryMutations, ConfigMutations<FacetsState>
```
**Extends:** [StatusMutations](./x-components.statusmutations.md)<!-- -->, [QueryMutations](./x-components.querymutations.md)<!-- -->, [ConfigMutations](./x-components.configmutations.md)<!-- --><[FacetsState](./x-components.facetsstate.md)<!-- -->>
## Properties
<table><thead><tr><th>
Property
</th><th>
Modifiers
</th><th>
Type
</th><th>
Description
</th></tr></thead>
<tbody><tr><td>
[clearStickyFilters](./x-components.facetsmutations.clearstickyfilters.md)
</td><td>
</td><td>
() => void
</td><td>
Removes all the filters from the [sticky filters](./x-components.facetsstate.stickyfilters.md) record.
</td></tr>
<tr><td>
[mutateFilter](./x-components.facetsmutations.mutatefilter.md)
</td><td>
</td><td>
(payload: [MutateFilterPayload](./x-components.mutatefilterpayload.md)<!-- -->) => void
</td><td>
Updates the state of a filter.
</td></tr>
<tr><td>
[removeFacet](./x-components.facetsmutations.removefacet.md)
</td><td>
</td><td>
(facet: Facet) => void
</td><td>
Removes the facet from the [facets](./x-components.facetsstate.facets.md) record.
</td></tr>
<tr><td>
[removeFilter](./x-components.facetsmutations.removefilter.md)
</td><td>
</td><td>
(filter: Filter) => void
</td><td>
Removes the filter from the [filters](./x-components.facetsstate.filters.md) record.
</td></tr>
<tr><td>
[removeFilters](./x-components.facetsmutations.removefilters.md)
</td><td>
</td><td>
(filters: Filter\[\]) => void
</td><td>
Removes a list of filters from the [filters](./x-components.facetsstate.filters.md) record.
</td></tr>
<tr><td>
[removeStickyFilter](./x-components.facetsmutations.removestickyfilter.md)
</td><td>
</td><td>
(filter: RawFilter) => void
</td><td>
Removes the filter from the [sticky filters](./x-components.facetsstate.stickyfilters.md) record.
</td></tr>
<tr><td>
[setFacet](./x-components.facetsmutations.setfacet.md)
</td><td>
</td><td>
(facet: Facet) => void
</td><td>
Adds the facet to the [facets](./x-components.facetsstate.facets.md) record.
</td></tr>
<tr><td>
[setFacetGroup](./x-components.facetsmutations.setfacetgroup.md)
</td><td>
</td><td>
(facetGroupEntry: [FacetGroupEntry](./x-components.facetgroupentry.md)<!-- -->) => void
</td><td>
Sets the group id of the facet.
</td></tr>
<tr><td>
[setFilters](./x-components.facetsmutations.setfilters.md)
</td><td>
</td><td>
(filters: Filter\[\]) => void
</td><td>
Adds a list of filters to the [filters](./x-components.facetsstate.filters.md) record.
</td></tr>
<tr><td>
[setOrigin](./x-components.facetsmutations.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>
[setParams](./x-components.facetsmutations.setparams.md)
</td><td>
</td><td>
(params: Dictionary<unknown>) => void
</td><td>
Sets the extra params of the module.
</td></tr>
<tr><td>
[setPreselectedFilters](./x-components.facetsmutations.setpreselectedfilters.md)
</td><td>
</td><td>
(filters: RawFilter\[\]) => void
</td><td>
Adds a list of filters to the [preselectedFilters](./x-components.facetsstate.preselectedfilters.md) record.
</td></tr>
<tr><td>
[setStickyFilter](./x-components.facetsmutations.setstickyfilter.md)
</td><td>
</td><td>
(filter: RawFilter) => void
</td><td>
Adds the filter to the [sticky filters](./x-components.facetsstate.stickyfilters.md) record.
</td></tr>
</tbody></table>