class Progress { pivot = 0 ; steps : number [ ] ; constructor ( steps ) { this . steps = steps ; } current ( ) { return this . steps [ this . pivot ] ; } next ( ) { if ( this . pivot < this . steps . length - 1 ) { this . pivot += 1 ; } return this . current ( ) ; } } export default Progress ;