Open ebouchut opened 10 months ago
I do have the same problem, but with HTML-comments like:
<!-- Kommentar -->
I would love to have this Bug fixed and see my comments again ;)
You can fix this with this workaround:
Change this:
.cm-line:not(:hover):not(.cm-active) span.cm-comment { display: none; }
to this:
/* .cm-line:not(:hover):not(.cm-active) span.cm-comment { display: none; } */
π Thank you @MAWSpitau for this workaround.
π§ I will try to build a CSS selector to only target/hide the Todoist comments.
I have a CSS rule handy to hide the start and end Obsidian comment surrounding the todoist_id
.
.cm-line:not(:hover):not(.cm-active) > .cm-comment.cm-comment-start:has(~ .dataview.inline-field > .dataview.inline-field-key[data-dv-key="todoist_id"]),
.cm-line:not(:hover):not(.cm-active) > .cm-comment.cm-comment-start:has(~ .dataview.inline-field > .dataview.inline-field-key[data-dv-key="todoist_id"]) ~ .cm-comment.cm-comment-end
{
display: none;
}
β This fixed the issue for me, it:
todoist_id
start and end comment delimiters (%%
) except when we hover over the line or edit the task. It is brittle because it depends on the CSS classes of the Tasks Obsidian plugin.
@MAWSpitau and anyone else interested, let me know if this works for you.
I also see this, so I like having a fix. Thank you! I've tried the fix, and it does not hide the todoist_id, so I've elected to just comment out the comment hiding CSS from styles.css for the time being. Either way, I'm grateful to have my comments back, so thank you guys :)
Regarding the final fix, I know my preferences are just that, mine, but I thought I'd share them just in case they are useful.
On a related note, I'm not sure if it's my mistake or some bug but I'm always able to see the todoist_id in edit mode, though the %%
are hidden when not moused over or editing the line. I haven't had time to investigate this yet.
π First off thank you @HeroBlackInk for this useful plugin.
I noticed the following issue.
Summary
When editing a note with a single-line comment in a language code block, with
Ultimate Todoist Sync for Obsidian
plugin enabled, then the comment is not shown (whatever the value ofEditing Mode
(Live Preview
orSource mode
)).Description of the Issue
When I type this in an Obsidian note:
β Whereas it is not when
Ultimate Todoist Sync for Obsidian
is enabled whatever the value ofEditing Mode
(Live Preview
orSource mode
), and I get this instead.FYI, the issue is the same for a single-line comment in a Ruby code block.