uphy / obsidian-reminder

Reminder plugin for Obsidian
https://uphy.github.io/obsidian-reminder/
MIT License
441 stars 34 forks source link

[Feature]: Support for callouts #91

Open redous1 opened 2 years ago

redous1 commented 2 years ago

Goal or desired outcome of this feature

I like to hide longer lists of tasks within callouts, often making them fold by default. Reminder appears not to support them.

Callouts can prefix tasks with multiple > signs if the callout is nested within other callouts:

> - [ ] Task (@2022-06-19 12:00)
> > - [ ] Task (@2022-06-19 12:00)
> ... > - [ ] Task (@2022-06-19 12:00)

Describe the feature

Reminder should support the > ... > pattern in front of tasks.

Screenshots, mockups, or videos

The reminders here should work:

> [!note] Tasks
> > [!attention]- Reminders
> > - [x] Reminder 1 (@2022-06-19 12:00)
> > - [ ] Reminder 2 (@2022-06-19 15:00)
uphy commented 2 years ago

Please try v1.1.10.

redous1 commented 2 years ago

It supports one level now. I think you need to change the regex from (> )? to (> )*, allowing 0 or more matches instead of 0 or 1.

redous1 commented 2 years ago

I tested it. The above change makes nested callouts work.

redous1 commented 2 years ago

Any chance you could implement the change I proposed here? I haven't experienced any noticeable slowdown regardless of the repetition operator.

uphy commented 2 years ago

Thank you for testing! I forgot to fix that. I will fix later.

uphy commented 2 years ago

@redous1 Supported nested-callouts with v1.1.12. Can you try it again?