diff --git a/src/web/reading_modal.py b/src/web/reading_modal.py index 212635a7..ddb0a835 100644 --- a/src/web/reading_modal.py +++ b/src/web/reading_modal.py @@ -574,34 +574,35 @@ def html(self) -> HTML: page_sidebar = str(conf_or_def("pdf.page_sidebar_shown", True)).lower() rev_overlay = "" - # check for last linked pages - last_linked = get_last_linked_notes(note_id, limit = 500) - if len(last_linked) > 0: - if hasattr(mw.col, "find_cards"): - due_today = mw.col.find_cards("(is:due or is:new or (prop:due=1 and is:review)) and (%s)" % " or ".join([f"nid:{nid}" for nid in last_linked])) - else: - due_today = mw.col.findCards("(is:due or is:new or (prop:due=1 and is:review)) and (%s)" % " or ".join([f"nid:{nid}" for nid in last_linked])) - if due_today and len(due_today) > 0 and get_config_value("notes.show_linked_cards_are_due_overlay"): - act = "Reading" - if note.is_pdf(): - ntype = "PDF" - elif note.is_yt(): - ntype = "video" - act = "Watching" + if get_config_value("notes.show_linked_cards_are_due_overlay"): + # check for last linked pages + last_linked = get_last_linked_notes(note_id, limit = 500) + if len(last_linked) > 0: + if hasattr(mw.col, "find_cards"): + due_today = mw.col.find_cards("(is:due or is:new or (prop:due=1 and is:review)) and (%s)" % " or ".join([f"nid:{nid}" for nid in last_linked])) else: - ntype = "note" - - rev_overlay = f""" -