vonshednob / pter

Manage your todo.txt in a commandline user interface (TUI)
https://vonshednob.cc/pter/
MIT License
102 stars 6 forks source link

Consistency issue when searching for done: and due: #44

Closed andrei-a-papou closed 5 months ago

andrei-a-papou commented 6 months ago

When searching, there seems to be a UX consistency issue between done: and due:.

Done searches:

  1. done:yes -- works
  2. done:y -- works
  3. done:no -- works
  4. done:n -- works

Due date searches:

  1. due:yes -- works
  2. due:y -- works
  3. due:no -- works
  4. due:n -- does NOT work

In addition, there's a difference between due: and done: (when no value is specified). The former works as due:today while the latter works as done:any (no such value has been implemented for now).

Personally, I would make the "empty value" behavior explicit. When no value is specified, the behavior is not clear (at least when enough tasks match the search).

Perhaps the "any" value should be implemented here as well, as discussed in #38? That way:

  1. due: and done: would not match anything because no value has been specified
  2. due:any would show tasks that have a non-empty due: tag
  3. done:any would show all tasks (same as done: does now, but explicitly to the user)

@vonshednob What are your thoughts?

vonshednob commented 6 months ago

Hm, I was thinking about the any value and I think it should probably be the explicit version of just the tag, i.e. due: being the same as due:any, the latter just being explicit.

I agree very much with due: not being due:today. At the time of writing that feature had not existed, so it was kinda difficult to estimate the use and usefulness. due:any is important and is not implemented. So, I’ll fix this together with #38

andrei-a-papou commented 6 months ago

Hm, I was thinking about the any value and I think it should probably be the explicit version of just the tag, i.e. due: being the same as due:any, the latter just being explicit.

Sounds good to me, as long as it's consistent with other shorthand/empty-value versions, like h: and t:

vonshednob commented 5 months ago

And done! See here

andrei-a-papou commented 5 months ago

OK, done:y, done:n, done:any, done: work fine. Dues seem to work fine too, thank you!