I would like to add to the code below as many options as possible to display how much time has passed. Right not I have Hours:Minuts:Seconds ... I was thinking of Years:Months:Weeks:Hours:Minutes:Seconds. Is something like this possible?
final currentTimestamp = Timestamp.now();
final timestamp = currentTimestamp.seconds;
final firestoreTimestamp = widget.timestamp;
final diff = timestamp - firestoreTimestamp.seconds;
timerSubscription = timerStream.listen((int newTick) {
if (!mounted) return;
setState(() {
hoursStr = (((newTick + diff) / (60 * 60)) % 60)
.floor()
.toString()
.padLeft(2, '0');
minutesStr =
(((newTick + diff) / 60) % 60).floor().toString().padLeft(2, '0');
secondsStr = ((newTick + diff) % 60).floor().toString().padLeft(2, '0');
});
})