Skip to content

Commit 4e23930

Browse files
Update src/Slider.tsx
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
1 parent ed2438b commit 4e23930

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/Slider.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -333,7 +333,7 @@ const Slider = React.forwardRef<SliderRef, SliderProps<number | number[]>>((prop
333333
const insertIndex = index === -1 ? rawValues.length : index;
334334
newDisabled.splice(insertIndex, 0, false);
335335
} else if (cloneNextValues.length < rawValues.length) {
336-
const index = rawValues.findIndex((item) => !cloneNextValues.includes(item));
336+
const index = rawValues.findIndex((item, i) => item !== cloneNextValues[i]);
337337
newDisabled.splice(index, 1);
338338
}
339339

0 commit comments

Comments
 (0)