UIZE JavaScript Framework


In this example, an instance of Uize.Widget.Bar.Progress is being used to provide crude feedback on the progress of a task of indeterminate length (such as an AJAX request). To simulate the start of the task, click the button. The progress indicator appears and a JavaScript animation is used to begin animating the estimated progress. To simulate the completion of the task, click the button again. The progress indicator will indicate that the task is complete and then disappear after a brief delay. This gives the user a positive confirmation signal that the task has completed.

Over the course of multiple simulated tasks, the progress bar will aggregate the task time and attempt to become more accurate at estimating time for the next task and update its animation speed accordingly. When used with AJAX applications, this can help the progress indicator to tune itself to connection speed and load factors for the application.