'How to make Audio Trimming widget in flutter And wave graph for sound

I am new in flutter.
I want to trim a audio.

Flutter Audio Wave

Flutter Audio Wave

I got the audiocutter package to implement trimming.
But problem is that "How to get input from the user in better UI?".
I searched about that, but not get any proper solution.

So, how to make widget like below to get input from user?



Solution 1:[1]

enter image description here

You want to create widget like above.
Then you can add wave_slider file and use following code.

WaveSlider(
  backgroundColor: Colors.grey.shade300,
  heightWaveSlider: 100,
  widthWaveSlider: 300,
  duration: 12.0,
  callbackStart: (duration) {
    print("Start $duration");
  },
  callbackEnd: (duration) {
    print("End $duration");
  },
)

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Chirag Kothiya