plugin-data.html.twig 2.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. <table>
  2. {% if plugin.author %}
  3. <tr>
  4. <td>{{ "PLUGIN_ADMIN.AUTHOR"|t }}:</td>
  5. <td class="double">
  6. {% if plugin.author.url %}
  7. <a href="{{ plugin.author.url }}" target="_blank" rel="noopener noreferrer">{{ plugin.author.name }}</a>
  8. {% else %}
  9. {{ plugin.author.name }}
  10. {% endif %}
  11. {% if plugin.author.email %}
  12. - <a href="mailto:{{ plugin.author.email }}">{{ plugin.author.email }}</a>
  13. {% endif %}
  14. </td>
  15. </tr>
  16. {% endif %}
  17. {% if plugin.homepage %}
  18. <tr>
  19. <td>{{ "PLUGIN_ADMIN.HOMEPAGE"|t }}:</td>
  20. <td class="double"><a href="{{ plugin.homepage }}" target="_blank" rel="noopener noreferrer">{{ plugin.homepage }}</a></td>
  21. </tr>
  22. {% endif %}
  23. {% if plugin.demo %}
  24. <tr>
  25. <td>{{ "PLUGIN_ADMIN.DEMO"|t }}:</td>
  26. <td class="double"><a href="{{ plugin.demo }}" target="_blank" rel="noopener noreferrer">{{ plugin.demo }}</a></td>
  27. </tr>
  28. {% endif %}
  29. {% if plugin.bugs %}
  30. <tr>
  31. <td>{{ "PLUGIN_ADMIN.BUG_TRACKER"|t }}:</td>
  32. <td class="double"><a href="{{ plugin.bugs }}" target="_blank" rel="noopener noreferrer">{{ plugin.bugs }}</a></td>
  33. </tr>
  34. {% endif %}
  35. {% if plugin.keywords %}
  36. <tr>
  37. <td>{{ "PLUGIN_ADMIN.KEYWORDS"|t }}:</td>
  38. <td class="double">{{ plugin.keywords|join(', ') }}</td>
  39. </tr>
  40. {% endif %}
  41. {% if plugin.license %}
  42. <tr>
  43. <td>{{ "PLUGIN_ADMIN.LICENSE"|t }}:</td>
  44. {% if plugin.license|starts_with('http') %}
  45. <td class="double"><a href="{{ plugin.license }}" target="_blank">{{ plugin.license }}</a></td>
  46. {% else %}
  47. <td class="double">{{ plugin.license }}</td>
  48. {% endif %}
  49. </tr>
  50. {% endif %}
  51. {% if plugin.description %}
  52. <tr>
  53. <td>{{ "PLUGIN_ADMIN.DESCRIPTION"|t }}:</td>
  54. <td class="double">{{ plugin.description_html|raw }}</td>
  55. </tr>
  56. {% endif %}
  57. {% if plugin.readme or plugin.homepage %}
  58. {% set readme_link = plugin.readme ?: plugin.docs|default(plugin.homepage ~ '/blob/master/README.md') %}
  59. <tr>
  60. <td>{{ plugin.readme ? "PLUGIN_ADMIN.README"|t : "PLUGIN_ADMIN.DOCS"|t }}:</td>
  61. <td class="double"><a href="{{ readme_link }}" target="_blank" rel="noopener noreferrer">{{ readme_link }}</a></td>
  62. </tr>
  63. {% endif %}
  64. {% if admin.gpm.findPackage(plugin.slug, true).changelog %}
  65. <tr>
  66. <td>{{ "PLUGIN_ADMIN.CHANGELOG"|t }}:</td>
  67. <td class="double"><a class="button button-small" href="#" data-remodal-target="changelog" data-remodal-changelog="{{ admin_route('/changelog/slug:' ~ plugin.slug) }}"><i class="fa fa-binoculars"></i> View Changelog</a></td>
  68. </tr>
  69. {% endif %}
  70. </table>