Invoice Custom Field transforms carriage return symbol into space

Hi everybody!

I use Invoice Ninja v5.4.9-C87.

Steps to reproduce the problem:

  1. Settings (Advanced settings) > Custom Fields > Invoices. Create a custom multiline invoice field.
  2. Fill created multiline field with multiline content.
  3. In rendered invoice carriage return symbols are transformed into spaces.

Fill the custom field with:

First line
Second line

And I’ll see in the rendered invoice:

First line Second line

Is it correct behavior?

PS I can put <br> tag in the end of each line to fix the issue, but I think it pollutes my text with HTML symbols.

UPD I have “Enable PDF Markdown” enabled in Settings > Account Management, but it does not work in the custom field. Is it correct behavior?


If markdown is enabled you need to use two line breaks, alternatively you can disable the markdown option.

Hmmm. Markdown is enabled. I enabled the option “Enable PDF Markdown” in Settings > Account Management, but it does not work in the custom field (but works in Product Description field, for example).

It may help to disable the option

It doesn’t help.

  1. Disabled option.
  2. Saved.
  3. Enabled option.
  4. Saved.
  5. Tried to edit custom field — generated PDF still ignores markdown. “View PDF” after “Save” ignores markdown in custom field too.

I’ll use HTML <br> tags, but just know that there may be problem / bug.

@david any thoughts?