table.blade.php 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
  5. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  6. <title>Document</title>
  7. <style>
  8. @font-face{
  9. font-family: 'NanumGothic-Regular';
  10. src: url("{{ storage_path('fonts/NanumGothic-Regular.ttf') }}") format('truetype');
  11. }
  12. @font-face{
  13. font-family: 'NanumGothic-Bold';
  14. src: url("{{ storage_path('fonts/NanumGothic-Bold.ttf') }}") format('truetype');
  15. }
  16. * {
  17. font-family: 'NanumGothic-Regular', 'NanumGothic-Bold';
  18. }
  19. .table-row th {
  20. text-align: center;
  21. padding: 8px 15px;
  22. background-color: #5c6bc0;
  23. color: white;
  24. border-right: 1px #ddd solid;
  25. font-weight: 400;
  26. }
  27. .table-col, .table-row { width: 100%; }
  28. .table-row td {
  29. text-align: center;
  30. border-bottom: 1px #ddd solid;
  31. border-right: 1px #ddd solid;
  32. }
  33. .table-row tr td:first-child { border-left: 1px #ddd solid; }
  34. </style>
  35. </head>
  36. <body>
  37. <div class="table-responsive mt-2">
  38. <table class="table-row">
  39. <thead id="table-head">
  40. <tr>
  41. @foreach ($table['head'] as $title)
  42. <th>{{ $title }}</th>
  43. @endforeach
  44. </tr>
  45. </thead>
  46. <tbody id="table-body">
  47. @foreach ($table['body'] as $data)
  48. <tr>
  49. @foreach ($data as $title)
  50. <td>{{ $title }}</td>
  51. @endforeach
  52. </tr>
  53. @endforeach
  54. </tbody>
  55. </table>
  56. </div>
  57. </body>
  58. </html>