notes-android icon indicating copy to clipboard operation
notes-android copied to clipboard

Block quote isn't displayed correctly directly following a heading

Open devn1x opened this issue 2 years ago • 0 comments

Please use GitHub reactions 👍 to show that you are affected by the same issue. Please don't comment if you have no relevant information to add!

Describe the bug

When a block quote is added right after a heading (doesn't matter which one) without a newline in between, the block quote is not indented properly and doesn't have the vertical line in front. This also results in the cursor being offset to the right in wrapped lines as if the block quote was indented correctly, which is very confusing. The problem with the cursor only happens if the block quote is defined in a single line. It doesn't happen if the quote is at least two lines long.

To Reproduce Steps to reproduce the behavior:

  1. Create a note with the content
# This is a problem:
> This is a very long text to demonstrate that there is a bug within the nextcloud notes android app.

# This is not a problem:

> This is a very long text to demonstrate that there is a bug within the nextcloud notes android app.

# This is partially a problem:
> This is a very long text to demonstrate that there is a bug within the nextcloud notes android app.
> The cursor is fine.
  1. Open the note in the app with the simple editor.
  2. Move the cursor into one of the wrapped lines of the quote.

Expected behavior

I would expect the block quote to be displayed correctly, even if there is no space in between the heading and the quote. Also I would expect that even if it wasn't displayed quite right, it should have an effect on the cursor position, adjusting it to the actual indentation.

Screenshots

Example 1: bugreport-example1 Example 2: bugreport-example2 Example 3: bugreport-example3

Smartphone:

  • Nextcloud Notes-Version (android app): 4.0.0
  • F-Droid or Play Store: Play Store
  • Android-Version: 12
  • Device: OnePlus Nord 2 5G

Server

  • Nextcloud version: 26.0.0
  • Nextcloud Notes version (server app): 4.7.2

Stacktrace (not applicable)

devn1x avatar Mar 29 '23 22:03 devn1x