Why was this improvement made?
- This improvement was made to accurately count the total sleep hours and minutes you had. This is more useful for those, such as myself, who use health trackers or use their own method to calculate whether or not they are getting enough sleep.
What does it accomplish?
- This allows me to keep track of my sleep schedule in the database. If I see a period of poor sleep, I can easily review my Daily Quests database and review my entire day to determine what may be affecting my sleep schedule. This will allow me to document where sleep can be improved if affected by the plan of the day or what occurred that day in my reflection. Was it something I ate that day? A mistake I made? A conversation I had?, etc.
How does it work?
-
The originating source of this came from aNotioneer's blog[free]. ← The link takes you to a formula that will allow you to calculate the time from when you Slept to when you Woke up.
-
You will create two properties in your daily quest, in my case I used "Fell Asleep" and "Wake Up". These are both Date Properties

- The formula from the blog post will go into a formula property. For example, I used "💤 Total Time Slept"

- Using my example, I will replace "Task End" with Woke Up and "Task Start" with Fell Asleep. This was then pasted into my Formula from the second step above.
if(dateBetween(prop("Woke Up"), prop("Fell Asleep"), "minutes") < 60, format(dateBetween(prop("Woke Up"), prop("Fell Asleep"), "minutes")) + " m", format(dateBetween(prop("Woke Up"), prop("Fell Asleep"), "hours")) + " h " + format(dateBetween(prop("Woke Up"), prop("Fell Asleep"), "minutes") - floor(dateBetween(prop("Woke Up"), prop("Fell Asleep"), "minutes") / 60) * 60) + " m")
- To test this, simply put in a date with a timestamp to watch it calculate for you!
<aside>
🚨 Do not touch the "Slept Enough" formula property from your system, this works as intended!!
</aside>
