mirror of
https://github.com/logseq/logseq.git
synced 2026-04-29 08:26:40 +00:00
fix: display hint when there's no card yet
Instead of saying that finished all cards.
This commit is contained in:
@@ -274,10 +274,21 @@
|
||||
(:block/title card-entity)))))))
|
||||
|
||||
[:span.text-sm.opacity-50 (str (min (inc @*card-index) (count @*block-ids)) "/" (count @*block-ids))]]
|
||||
(if-let [block-id (nth block-ids @*card-index nil)]
|
||||
[:div.flex.flex-col
|
||||
(card-view repo block-id *card-index *phase)]
|
||||
[:p (t :flashcards/modal-finished)])])))
|
||||
(let [block-id (nth block-ids @*card-index nil)]
|
||||
(cond
|
||||
block-id
|
||||
[:div.flex.flex-col
|
||||
(card-view repo block-id *card-index *phase)]
|
||||
|
||||
(empty? block-ids)
|
||||
[:div.ls-card.content.ml-2
|
||||
[:h2.font-medium (t :flashcards/modal-welcome-title)]
|
||||
|
||||
[:div
|
||||
[:p (t :flashcards/modal-welcome-desc-1)]]]
|
||||
|
||||
:else
|
||||
[:p (t :flashcards/modal-finished)]))])))
|
||||
|
||||
(defonce ^:private *last-update-due-cards-count-canceler (atom nil))
|
||||
(def ^:private new-task--update-due-cards-count
|
||||
|
||||
Reference in New Issue
Block a user