After tirelessly searching, I finally found a solution using an HTML Progress Bar to track my shipments.
The progress can be updated based on the shipping status, and currently, I am utilizing the $interval
function to update the progress every three seconds.
var app = angular.module("shipment_tracker", []);
app.controller('progressCtrl',function($scope, $interval){
$scope.progress_value=10;
$scope.title="Shipment Progress";
$scope.updateProgress = function() {
if($scope.progress_value <=100){
$scope.progress_value = $scope.progress_value + 10;
}else{
$scope.progress_value = 0;
}
}
$interval( function(){ $scope.updateProgress(); }, 3000);
});
.tracker {
width:70%
}
<!DOCTYPE html>
<html>
<head>
<script src="http://ajax.googleapis.com/ajax/libs/angularjs/1.4.8/angular.min.js"></script>
</head>
<body ng-app="shipment_tracker" ng-controller="progressCtrl">
<h3 ng-bind='title'> </h3><br/><br/>
<progress value="{{progress_value}}" max="100" class="tracker">
</progress>
</body>
</html>