problems.html.twig 3.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="utf-8" />
  5. <title>Grav Problems</title>
  6. <meta name="description" content="Grav is an easy to use, yet powerful, open source flat-file CMS">
  7. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  8. <link rel="stylesheet" href="{{ problems_url }}/css/spectre.min.css" type="text/css" />
  9. <link rel="stylesheet" href="{{ problems_url }}/css/spectre-icons.min.css" type="text/css" />
  10. </head>
  11. <body>
  12. <div class="container grid-md">
  13. <div class="columns">
  14. <div class="column">
  15. <div class="text-center">
  16. <img class="logo" src="{{ problems_url }}/assets/grav-logo.svg" />
  17. <p class="reload toast toast-primary">
  18. Please <strong>Review</strong> and <strong>Resolve</strong> before continuing <a href="{{ base_url }}" class="btn btn-primary"><i class="icon icon-refresh"></i> Reload Page</a>
  19. </p>
  20. </div>
  21. <ul class="problems">
  22. {% for problem in problems %}
  23. {% set status = problem.status ? 'success' : problem.level == 'critical' ? 'error' : 'warning' %}
  24. <li class="menu">
  25. <div class="toast toast-{{ status }}">
  26. <strong>{{ problem.id }}:</strong>
  27. {{ problem.msg|raw }}
  28. {% if problem.help %}<a href="{{ problem.help }}" class="btn btn-sm btn-{{ status }}" target="_blank"><i class="icon icon-bookmark"></i> Help</a>{% endif %}
  29. </div>
  30. {% if problem.details is iterable %}
  31. <ul class="details">
  32. {% for key,value in problem.details.errors %}
  33. <li class="menu-item">
  34. <div class="menu-badge">
  35. <label class="label label-error"><i class="icon icon-cross"></i></label>
  36. </div>
  37. <span class="active"><code>{{ key }}</code> - {{ value }}</span>
  38. </li>
  39. {% endfor %}
  40. {% for key,value in problem.details.success %}
  41. <li class="menu-item">
  42. <div class="menu-badge">
  43. <label class="label label-success"><i class="icon icon-check"></i></label>
  44. </div>
  45. <span class=""><code>{{ key }}</code> - {{ value }}</span>
  46. </li>
  47. {% endfor %}
  48. </ul>
  49. {% endif %}
  50. </li>
  51. {#{% for msg in type %} %}#}
  52. {#<li class="{{ type }}">{{ msg }}</li>#}
  53. {#{% endfor %}#}
  54. {% endfor %}
  55. </ul>
  56. <p class="footer text-center">
  57. <a href="http://getgrav.org">Grav</a> was <img src="{{ problems_url }}/assets/code-3.svg" /> with <img class="love" src="{{ problems_url }}/assets/heart.svg" /> by <a href="https://trilby.media">Trilby Media</a>.
  58. </p>
  59. </div>
  60. </div>
  61. </div>
  62. </body>
  63. </html>