SwiftUI Slider onEditingChanged is unreliable on iOS 26

For information I stumbled upon a regression with SwiftUI Slider on iOS 26. Its onEditingChanged closure might be called twice when interaction ends, with a final Boolean incorrect value of true provided to the closure.

As a result apps cannot reliably rely on this closure to detect when an interaction with the slider starts or ends.

I filed a feedback under FB20283439 (iOS 26.0 regression: Slider onEditingChanged closure is unreliable).

Thank you for your post. And thanks for the bug report. What version of Xcode and iOS are you using?

Slider(value: $progress) { isEditing in
            print("--> isEditing: \(isEditing)")
        }
--> isEditing: true
--> isEditing: false

Upon examining the Slider component, I have observed that when the slider is moved to any value, two calls are triggered. The first call is initiated when the editing mode is activated, and the second call is triggered after the user ceases interacting with the slider. Kindly update to the latest Xcode and iOS versions and provide an update on this matter. Thanks

Albert Pascual
  Worldwide Developer Relations.

Hi Albert,

Thank you very much for your quick answer.

I was running Xcode 26 RC1 but I just updated to the final release (17A324). My iPhone 14 Pro is running iOS 26 final (23A341) and I can also reproduce the issue on another iPad Pro device running iPadOS 26 final as well.

I updated my bug report with a video that shows that, in my case, I usually obtain:

--> isEditing: true
--> isEditing: false
--> isEditing: true

when dragging the slider knob once (the two last events being received when releasing the knob).

Thanks again for your help.

Best regards.

I also ran into the same problem. The callback state of onEditingChanged does not match the actual behavior.

Same problem here. It happens about 50% of the time with a Slider setup like this:

Slider(
    value: $playerVm.curTime,
    in: 0...playerVm.maxTime,
    onEditingChanged: { editing in
        playerVm.isDraggingTime = editing
    }
)

Similar to the original report, when finished dragging the thumb, will get an instant editing value of false, and then a couple milliseconds later will get an editing value of true.

Any new insights here? I'm struggling with exactly the same problem.

I am experiencing the same bug. On iOS 18 and older, when I move a slider, the last value reported by onEditingChanged returns false, as expected.

But now on my iPhone 15 Pro running iOS 26.1 and built with Xcode Version 26.1 (17B55), the last reported value for the slider's onEditingChanged is still returning true for the final value when I lift my finger off the slider.

Hi everyone,

I wanted to share an additional finding that might help narrow down the issue. In my case, the unexpected behavior of onEditingChanged appears only when the Slider uses the step parameter.

Here is a minimal reproducible example:

@State private var speed = 50.0
@State private var isEditing = false {
    didSet {
        print("isEditing:\(isEditing)")
    }
}

var body: some View {
    VStack {
        Slider(
            value: $speed,
            in: 0...100,
            step: 10,
            onEditingChanged: { editing in
                isEditing = editing
            }
        )
        Text("\(speed)")
            .foregroundColor(isEditing ? .red : .blue)
    }
}

✔️ Without the step parameter (works as expected):

Start dragging:

isEditing: true

End dragging:

isEditing: false

❌ With the step parameter:

Start dragging: (no logs at all)

End dragging:

isEditing:false

isEditing:true

So the final editing state becomes true again when the drag gesture ends — matching what others here have observed.

Additional details:

  • Issue reproduces on iOS 26.1
  • Worked correctly on iOS 26.0.1
  • Tested with Xcode Version 26.1.1 (17B100)

It seems the presence of a step value triggers an extra internal state change at the end of the interaction, causing onEditingChanged to fire incorrectly.

Hopefully this helps Apple engineers pinpoint the regression more easily.

Best regards,

Luka

SwiftUI Slider onEditingChanged is unreliable on iOS 26
 
 
Q