NumericFacetActions
NumericFacetActions
This is for:
DeveloperThe numeric facet action creators.
See Dispatch Actions.
Loader Function
loadNumericFacetActions
Loads the commerce facet set reducer and returns the available numeric facet action creators.
Parameters
-
engine:
CommerceEngine
The commerce engine.
Returns NumericFacetActionCreators
: The numeric facet action creators.
NumericFacetActionCreators
toggleExcludeNumericFacetValue
Toggles the exclusion state of a given numeric facet value.
Parameters
-
payload:
ToggleSelectNumericFacetValuePayload
The action creator payload.
Returns PayloadAction<ToggleExcludeNumericFacetValuePayload>
: A dispatchable action.
toggleSelectNumericFacetValue
Toggles the selection state of a given numeric facet value.
Parameters
-
payload:
ToggleSelectNumericFacetValuePayload
The action creator payload.
Returns PayloadAction<ToggleSelectNumericFacetValuePayload>
: A dispatchable action.
updateNumericFacetValues
Updates all values in a given numeric facet.
Parameters
-
payload:
UpdateNumericFacetValuesPayload
The action creator payload.
Returns PayloadAction<UpdateNumericFacetValuesPayload>
: A dispatchable action.
Related Types
NumericRangeRequest
Properties
-
end:
number
The end value of the range.
-
endInclusive:
boolean
Whether to include the
end
value in the range. -
start:
number
The start value of the range.
-
state:
FacetValueState
The current facet value state.
ToggleSelectNumericFacetValuePayload
Properties
-
facetId:
string
The unique identifier of the facet (e.g.,
"1"
). -
selection:
NumericRangeRequest
The target numeric facet value.
UpdateNumericFacetValuesPayload
Properties
-
facetId:
string
The unique identifier of the facet (e.g.,
"1"
). -
values:
NumericRangeRequest[]
The numeric facet values.