heyman / heynote

A dedicated scratchpad for developers
https://heynote.com
Other
3.86k stars 194 forks source link

Bug: blank lines at end of Markdown blocks are not collapsed #195

Open simonratner opened 7 months ago

simonratner commented 7 months ago

Describe the bug When markdown block ends with one or more blank lines, those lines remain in collapsed view.

To Reproduce

  1. Create a markdown block ending in blank lines:
    
    Markdown collapsed example
    --------------------------

First line Second line


![image](https://github.com/heyman/heynote/assets/667283/e94df437-c92d-4daa-a539-40437b698e74)

2. Collapse it:

![image](https://github.com/heyman/heynote/assets/667283/60a3d328-a9cb-4115-ba14-f61d93ef06c6)

**Expected behavior**
Trailing blank lines are not visible when collapsed.

**Desktop (please complete the following information):**
 - OS: Win11
 - Version 1.7.0