-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add a new AboutCode tab in Package details view #42
Signed-off-by: tdruez <tdruez@nexb.com>
- Loading branch information
Showing
2 changed files
with
34 additions
and
0 deletions.
There are no files selected for viewing
21 changes: 21 additions & 0 deletions
21
component_catalog/templates/component_catalog/tabs/tab_aboutcode.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
<div class="alert alert-primary m-0 mb-3" role="alert"> | ||
<p class="m-0"> | ||
This tab renders a preview of the AboutCode files: .ABOUT and .NOTICE, | ||
exactly as it will appear in the generated .yml files.<br> | ||
<a href="{{ object.get_about_files_url }}" class="fw-bold">Click here to download</a> | ||
those files as a zip archive. | ||
</p> | ||
</div> | ||
|
||
<dl class="row mb-0"> | ||
<dt class="col-sm-1 text-end pt-2 pe-0">.ABOUT</dt> | ||
<dd class="col-sm-11"> | ||
<pre class="pre-bg-body-tertiary mb-1">{{ values.about_content }}</pre> | ||
</dd> | ||
{% if values.notice_content %} | ||
<dt class="col-sm-1 text-end pt-2 pe-0">.NOTICE</dt> | ||
<dd class="col-sm-11"> | ||
<pre class="pre-bg-body-tertiary mb-1">{{ values.notice_content }}</pre> | ||
</dd> | ||
{% endif %} | ||
</dl> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters