diff --git a/src/App.js b/src/App.js index 153756f..fbc849a 100755 --- a/src/App.js +++ b/src/App.js @@ -382,6 +382,8 @@ function App() { const [succeeded,setSucceeded] = useState(0) const [failed,setFailed] = useState(0) const [total,setTotal] = useState(0) + const [itemCount,setItemCount] = useState() + const [totalItemCount,setTotalItemCount] = useState() const [craftsRatio,setCraftsRatio] = useState(0) const [missingCraftsRatio,setMissingCraftsRatio] = useState(0) const [inProgressRatio,setInProgressRatio] = useState(0) @@ -439,6 +441,8 @@ function App() { } tot+=Number(item.required) } + setItemCount(itemsComplete+itemsInProgress+itemsCrafts) + setTotalItemCount(tot) setMissingCraftsRatio(((totCrafts-itemsCrafts)/tot*100).toFixed(2)) setMissingProgressRatio(((totItemsInProgress-itemsInProgress)/tot*100).toFixed(2)) setCompleteRatio((itemsComplete/tot*100).toFixed(2)) @@ -529,6 +533,8 @@ function App() { } tot+=Number(item.required) } + setItemCount(itemsComplete+itemsInProgress+itemsCrafts) + setTotalItemCount(tot) setMissingCraftsRatio(((totCrafts-itemsCrafts)/tot*100).toFixed(2)) setMissingProgressRatio(((totItemsInProgress-itemsInProgress)/tot*100).toFixed(2)) setCompleteRatio((itemsComplete/tot*100).toFixed(2)) @@ -659,7 +665,7 @@ function App() { data.length>0? <> -

{Number(completeRatio)+Number(inProgressRatio)+Number(craftsRatio)}% complete

+ {(Number(completeRatio)+Number(inProgressRatio)+Number(craftsRatio))}% complete({itemCount.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ",") + " / " + totalItemCount.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ",")})