Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Possible bug when rendering notification email with markdown syntax #21197

Closed
wanghanlin opened this issue Sep 15, 2017 · 1 comment
Closed

Comments

@wanghanlin
Copy link
Contributor

  • Laravel Version: 5.4/5.5
  • PHP Version: not related
  • Database Driver & Version: not related

Description:

There is a bug if using markdown list syntax in default html email message will cause the last element of the list have wrong css. this is related to underlying erusev/parsedown package but I'm wondering if we can prevent this error on our side, like if developer not using markdown email, we force render it as raw text?
An issue is created on parsedown repo erusev/parsedown#529

Steps To Reproduce:

having code like this in notification

        return (new MailMessage)
                    ->line('- A')
                    ->line('- B')
                    ->line('- C')

laravel will send following text to parsedown, for clear view, \n tag is added.

- A \n
\n
- B \n
\n
- C \n
\n

and parsedown will convert to

   <ul>\n
   <li>\n
   <p>A</p>\n
   </li>\n
   <li>\n
   <p>B</p>\n
   </li>\n
   <li>C</li>\n
   </ul>

while it supposed to be

   <ul>\n
   <li>\n
   <p>A</p>\n
   </li>\n
   <li>\n
   <p>B</p>\n
   </li>\n
   <li>\n
   <p>C</p>\n
   </li>\n
   </ul>
@wanghanlin
Copy link
Contributor Author

This issue is similar as erusev/parsedown#474 and should be able to work once erusev/parsedown#475 is merged. In case of others having this issue, I think it's better increase the version in composer.json once that patch is merged

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants