Files
clear-linux-documentation/source/_scripts/_python/template.html
T
michael vincerra 4925650c45 Add code to show status and assign status color-code for available bundles. (#748)
* Add code to show status and assign color-coding to available bundles.
- Add regex PATTERN4 to capture bundle status values
- Add code to process capture groups in for loop
- Rename bundler() to main() to follow Python convention
- Add conditional blocks to filter tags based on below status indicators
- Add css classes for active-status, wip-status, and pending-delete-status
- Closes #747

Signed-off-by: Michael Vincerra <michael.vincerra@intel.com>

* Programs "Deprecated" status for such bundles; color-codes it in css.

Signed-off-by: Michael Vincerra <michael.vincerra@intel.com>

* Adds #ce2029 color for "Deprecated" status to css; reorders css classes.

Signed-off-by: Michael Vincerra <michael.vincerra@intel.com>

* Revises HTML relative link in template.html to tcs_theme.css.

Signed-off-by: Michael Vincerra <michael.vincerra@intel.com>
2019-08-29 13:50:30 -07:00

72 lines
1.9 KiB
HTML

<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Bundles in Clear Linux* OS</title>
<link rel="stylesheet" type="text/css" href="../../_themes/otc_tcs_sphinx_theme/static/tcs_theme.css">
</head>
<body>
<div class="wy-table-responsive">
<table class="colwidths-given docutils">
<thead>
<tr>
<th></th>
<th style="text-align:right; font-family:IntelClear-Regular,Helvetica,Arial; font-style:italic">
Updated: {{ now.strftime('%x %H:%M') }} UTC
</th>
</tr>
<tr>
<th> Name</th>
<th> Description</th>
</tr>
</thead>
<tbody>
{% for d in data %}
{% if d.url %}
<tr id="bundle">
<td class="bundlename" id="bundle"><a href="{{d.url}}">{{d.title}}</a></td>
<td class="bundledesc">{{d.data_desc}} <br />
<div> Status:
{% if d.status=="Pending-Delete" %}
<span class="pending-delete-status">{{d.status}}</span>
{% elif d.status=="Active" %}
<span class="active-status">{{d.status}}</span>
{% elif d.status=="WIP" %}
<span class="wip-status">{{d.status}}</span>
{% elif d.status=="Deprecated"%}
<span class="deprecated-status">{{d.status}}</span>
{% else %}
<span>{{d.status}}</span>
{% endif %}
</div>
{% if d.include_list %}
<div class="bundledesc">Includes bundle(s):
<ul>
{% for include in d.include_list %}
<li>{{include}}</li>
{% endfor %}
</ul>
</div>
{% endif %}
</td>
</tr>
{% else %}
<tr id="pundle">
<td class="bundlename"><a href="{{d.purl}}">{{d.title}}</a></td>
<td class="bundledesc"> {{d.pun_desc}} </td>
</tr>
{% endif %}
{% endfor %}
</tbody>
</table>
</div>
</body>
</html>