Refactor progressBarWidth