In my opinion, the author of the post wants a uniform, smooth movement, so the clock speed must be as low as possible. The slider method won't really work here because the slider accuracy is low, as @Juan_Antonio mentioned. The slider will not have smooth motion, only jumps as seen in the @Anke app.
It's a good idea to use an arrangement or any other component and play with its width. Here is an example of a progress bar made with an arrange. Its accuracy is not based on the timing of the clock component, which we know is not very accurate. I achieved fluency and accuracy by reading the current state of the milis counter.
The same applies to your approach, with the small difference that here the jumps are shorter (at 30 min there are 5 sec intervals / jumps). However, smooth is different.
Yes, in the case of 30 minutes and the slider, the movement of the strip can be seen every 18 seconds, in the case of using a different component, every 4.5 seconds.
The vertical width of my screen is about 400px. If the app was operated horizontally, the smoothness of the bar would increase, while in the case of the slider it is always 100 points.
Firstly, my apologies because I am delaying my answers but, believe me, today was not an easy day for me.
Now, I'm going to do it one by one and, furthermore, I want to say all of you thanks for your advises because I have learned with you in a few hours more than I have learned in a month by myself.
Well, I tested your code and I can say that it works so fine, but it is not exactly what I'm looking for. However, I will keep it in mind for the future.
Thank you very much again. Recibe un muy cordial saludo,