Skip to content
This repository has been archived by the owner on Feb 23, 2024. It is now read-only.

Filter Products by Price: Decrease step sequence from 10 to 1 #6486

Merged
merged 1 commit into from
May 31, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions assets/js/base/components/price-slider/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -84,8 +84,8 @@ const PriceSlider = ( {
const minRange = useRef< HTMLInputElement >( null );
const maxRange = useRef< HTMLInputElement >( null );

// We want step to default to 10 major units, e.g. $10.
const stepValue = step ? step : 10 * 10 ** currency.minorUnit;
// We want step to default to 1 major unit, e.g. $1.
const stepValue = step ? step : 10 ** currency.minorUnit;

const [ minPriceInput, setMinPriceInput ] = useState( minPrice );
const [ maxPriceInput, setMaxPriceInput ] = useState( maxPrice );
Expand Down