diff options
author | Thanos Apollo <[email protected]> | 2024-08-07 01:40:04 +0300 |
---|---|---|
committer | Thanos Apollo <[email protected]> | 2024-08-07 01:40:04 +0300 |
commit | 0625ac6501884f6da8fa9fe7a55c006b328d3885 (patch) | |
tree | d8db1d4d0f4cbb7c4161db35ee8466de09b1cd46 | |
parent | 95fda0a8e3819f833334bbcfeda5fbe85be6dfe9 (diff) |
New function: get-note-proto.
-rw-r--r-- | gnosis.el | 9 |
1 files changed, 9 insertions, 0 deletions
@@ -2096,6 +2096,15 @@ CUSTOM-VALUES: Specify values for tags." proto-values))) (apply #'cl-mapcar #'max padded-lists)))) +(defun gnosis-get-note-proto (id &optional custom-tags custom-deck custom-values) + "Return tag proto values for note ID." + (let* ((deck (or custom-deck (gnosis-get-note-deck-name id))) + (tags (or custom-tags (gnosis-get 'tags 'notes `(= id ,id)))) + (proto-values (or (delq nil (append (gnosis-get-custom-tag-values nil :proto tags custom-values) + (list (gnosis-get-custom-deck-value deck :proto + custom-values)))) + gnosis-algorithm-proto))) + (gnosis-proto-max-values proto-values))) (defun gnosis-get-date-total-notes (&optional date) "Return total notes reviewed for DATE. |