Ionic 5 - Trouble with ion segment and ion slides

Hi, I’m developing an app for my University and I’ve a problem with ion-segment and ion-slides. The idea is to create a ion-segment with 2 buttons in order to change slide panels and viceversa. When I click on the button, the segment animation works perfectly, but when I swipe on slides to change the active segment value, the animation doesn’t work. Here an example:


Sorry but I am trying to see what exactly is wrong. But cool UI idea if u ask me!

I tried to solve simulating click on segment button when user swipes on slide. It works but I don’t think it’s a good way to solve this problem. Any suggestions?

sorry I can’t be of more support, as I still struggle to understand what is wrong and what you actually see as the desired UI in the video you have shown.

if you look better at the video you should see the following things:

  • a smooth indicator movement when user clicks on the segment-button;
  • an instantaneous movement when the user swipes the slide.

What I want is a smooth behaviour in both cases. Thanks.

Ok thx
Now I see

I dont know how u wired the segment to the slide, but assuming through ionChange on the segment to do a slide method and capturing a slide change to change the value of the segment-> i would consider a hack on the latter, where the slide change does not change the segment via the value binding but by emulating a click in the segment button

Any updates on this? Facing the same issue.