Skip to content

Commit

Permalink
Add "open" and "done" autotags
Browse files Browse the repository at this point in the history
  • Loading branch information
foxbenjaminfox committed Aug 14, 2023
1 parent 3c0117e commit 6176004
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions filter.js
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,15 @@ function automaticTags (elem) {

if (elem.dataset.coasting === 'true') autotags.push('coasting')
if (elem.dataset.hhmmformat === 'true') autotags.push('time')

const todayta = elem.querySelector('.todayta')

if (todayta && !todayta.classList.contains('hidden')) {
autotags.push('done')
} else {
autotags.push('open')
}

return autotags
}

Expand Down

0 comments on commit 6176004

Please sign in to comment.