Skip to content

Commit

Permalink
Prevent long URLs from breaking email layouts (#32189)
Browse files Browse the repository at this point in the history
  • Loading branch information
imacrayon authored Apr 2, 2020
1 parent 65a9230 commit 59dca48
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
6 changes: 6 additions & 0 deletions src/Illuminate/Mail/resources/views/html/themes/default.css
Original file line number Diff line number Diff line change
Expand Up @@ -290,3 +290,9 @@ img {
font-size: 15px;
text-align: center;
}

/* Utilities */

.break-all {
word-break: break-all;
}
6 changes: 2 additions & 4 deletions src/Illuminate/Notifications/resources/views/email.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -52,13 +52,11 @@
@slot('subcopy')
@lang(
"If you’re having trouble clicking the \":actionText\" button, copy and paste the URL below\n".
'into your web browser: [:displayableActionUrl](:actionURL)',
'into your web browser:',
[
'actionText' => $actionText,
'actionURL' => $actionUrl,
'displayableActionUrl' => $displayableActionUrl,
]
)
) <span class="break-all">[{{ $displayableActionUrl }}]({{ $actionUrl }})</span>
@endslot
@endisset
@endcomponent

1 comment on commit 59dca48

@Daniel-Mendes
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Your modifications brake the caouecs/Laravel-lang/ package because you removed the actionURL, see this issue and this PR.

Please sign in to comment.