Examples of code I've written in PHP, Javascript, SCSS, etc.
Vous ne pouvez pas sélectionner plus de 25 sujets Les noms de sujets doivent commencer par une lettre ou un nombre, peuvent contenir des tirets ('-') et peuvent comporter jusqu'à 35 caractères.
 
 
 
 
 
 

63 lignes
1.1 KiB

  1. @component('mail::message')
  2. {{-- Greeting --}}
  3. @if (! empty($greeting))
  4. # {{ $greeting }}
  5. @else
  6. @if ($level === 'error')
  7. # @lang('Whoops!')
  8. @else
  9. # @lang('Hello!')
  10. @endif
  11. @endif
  12. {{-- Intro Lines --}}
  13. @foreach ($introLines as $line)
  14. {{ $line }}
  15. @endforeach
  16. {{-- Action Button --}}
  17. @isset($actionText)
  18. <?php
  19. switch ($level) {
  20. case 'success':
  21. case 'error':
  22. $color = $level;
  23. break;
  24. default:
  25. $color = 'primary';
  26. }
  27. ?>
  28. @component('mail::button', ['url' => $actionUrl, 'color' => $color])
  29. {{ $actionText }}
  30. @endcomponent
  31. @endisset
  32. {{-- Outro Lines --}}
  33. @foreach ($outroLines as $line)
  34. {{ $line }}
  35. @endforeach
  36. {{-- Salutation --}}
  37. @if (! empty($salutation))
  38. {{ $salutation }}
  39. @else
  40. @lang('Regards'),<br>
  41. {{ config('app.name') }}
  42. @endif
  43. {{-- Subcopy --}}
  44. @isset($actionText)
  45. @slot('subcopy')
  46. @lang(
  47. "If you’re having trouble clicking the \":actionText\" button, copy and paste the URL below\n".
  48. 'into your web browser:',
  49. [
  50. 'actionText' => $actionText,
  51. ]
  52. ) <span class="break-all">[{{ $displayableActionUrl }}]({{ $actionUrl }})</span>
  53. @endslot
  54. @endisset
  55. @endcomponent