Commit fce4d8cf authored by Merret Buurman's avatar Merret Buurman
Browse files

CSS: Added warning sign if file parent is replaced.

parent 40bd303d
......@@ -50,6 +50,9 @@ hr
border-top: 1px solid #ddd;
}
/* Tables containing handle record info */
table
{
background-color: #f8ffff; /*transparent*/ /*#f0f4f4*/ /*f0f8f8*/ /*#f0fcfc*/
......@@ -59,11 +62,23 @@ table
width:100%;
}
tr #leftcol
th, td
{
width:30%;
padding: .5em 1em;
vertical-align: top;
text-align: left;
border-bottom: 1px solid #ddd;
}
/* Highlight when hovering over table rows: */
tr:hover {background-color: #e6ffff}
/* Column width */
tr .leftcol { width:23em; }
tr .leftcol_slim { width:18em; }
tr .middlecol { width:3em; }
/* A table row for the replacement warning */
table tr.note
{
background-color:white;
......@@ -77,8 +92,28 @@ span.note
span.attention
{
font-style: italic;
color:red;
color:#B40431;
background-color: #FBEFF5;
padding:.5em;
}
table tr td.replaced
{
width:35%;
color: red;
vertical-align: middle;
}
td.warning_icon_replaced
{
vertical-align: middle;
text-align:right;
padding-right: 0;
padding-left: 2em;
}
/* OTHER */
.filename
{
......@@ -91,25 +126,6 @@ span.attention
/*font-weight: bold; */
color:black; /*009d8f*/
}
/* Highlight when hovering over table rows: */
tr:hover {background-color: #e6ffff}
/* Stiped table: */
/*tr:nth-child(even) {background-color: #f2f2f2} */
th, td
{
padding: .5em 1em;
vertical-align: top;
text-align: left;
border-bottom: 1px solid #ddd;
}
a:link { color: royalblue; }
a:visited { color: purple; }
a:focus { color: black; }
a:hover { color: green; }
a:active { color: red; }
/* -----------------------
Layout styles
......@@ -373,3 +389,14 @@ img#source{
background: #caf7f7; /*green*/
}
/* Links */
a:link { color: royalblue; }
a:visited { color: purple; }
a:focus { color: black; }
a:hover { color: green; }
a:active { color: red; }
......@@ -53,23 +53,23 @@
<table>
{% if drs %}
<tr>
<td id="leftcol">DRS name</td>
<td class="leftcol">DRS name</td>
<td>{{drs}}</td>
</tr>
{% endif %}
{% if version %}
<tr>
<td id="leftcol">Version number</td>
<td class="leftcol">Version number</td>
<td>{{version}}</td>
</tr>
{% endif %}
<tr>
<td id="leftcol">Persistent identifier</td>
<td class="leftcol">Persistent identifier</td>
<td><a href="http://hdl.handle.net/{{handle}}">hdl:{{handle}}</a></td>
</tr>
{% if newerversion %}
<tr>
<td id="leftcol">Newer version</td>
<td class="leftcol">Newer version</td>
<td><a href="http://hdl.handle.net/{{handle}}">hdl:{{newerversion}}</a></td>
</tr>
{% endif %}
......@@ -85,7 +85,7 @@
{% if hosts_original %}
{% for entry in hosts_original %}
<tr>
<td id="leftcol">Hosted by <a href="{{entry.host}}">{{entry.host}}</a></td>
<td class="leftcol">Hosted by <a href="http://{{entry.host}}">{{entry.host}}</a></td>
<td></td>
</tr>
{% endfor %}
......@@ -93,7 +93,7 @@
{% if hosts_replica %}
{% for entry in hosts_replica %}
<tr>
<td id="leftcol">Mirrored at <a href="{{entry.host}}">{{entry.host}}</a></td>
<td class="leftcol">Mirrored at <a href="{{entry.host}}">{{entry.host}}</a></td>
<td></td>
</tr>
{% endfor %}
......@@ -110,7 +110,7 @@
<table>
{% for item in list_of_parts_records %}
<tr>
<td id="leftcol">{{item.level}}</td>
<td class="leftcol">{{item.level}}</td>
<td>
{{ item.title }}
{% if item.version %}
......
......@@ -56,29 +56,29 @@
<table>
{% if filename %}
<tr>
<td id="leftcol">File name</td>
<td class="leftcol">File name</td>
<td>{{filename}}</td>
</tr>
{% endif %}
<tr>
<td id="leftcol">Persistent identifier</td>
<td class="leftcol">Persistent identifier</td>
<td><a href="http://hdl.handle.net/{{handle}}">hdl:{{handle}}</a></td>
</tr>
{% if filesize %}
<tr>
<td id="leftcol">File size</td>
<td class="leftcol">File size</td>
<td>{{filesize}}</td>
</tr>
{% endif %}
{% if checksum and not checksum_method%}
<tr>
<td id="leftcol">Checksum</td>
<td class="leftcol">Checksum</td>
<td>{{checksum}}</td>
</tr>
{% else %}
{% if checksum and checksum_method %}
<tr>
<td id="leftcol">Checksum ({{checksum_method}})</td>
<td class="leftcol">Checksum ({{checksum_method}})</td>
<td>{{checksum}}</td>
</tr>
{% endif %}{% endif %}
......@@ -94,7 +94,7 @@
{% if urls_original %}
{% for entry in urls_original %}
<tr>
<td id="leftcol">Hosted by {{entry.host}}:</td>
<td class="leftcol">Hosted by {{entry.host}}:</td>
<td><a href="{{entry.url}}">{{entry.url}}</a></td>
</tr>
{% endfor %}
......@@ -102,7 +102,7 @@
{% if urls_replicas %}
{% for entry in urls_replicas %}
<tr>
<td id="leftcol">Mirrored at {{entry.host}}:</td>
<td class="leftcol">Mirrored at {{entry.host}}:</td>
<td><a href="{{entry.url}}">{{entry.url}}</a> (Replica)</td>
</tr>
{% endfor %}
......@@ -119,23 +119,29 @@
<table>
{% for item in list_of_aggregation_records %}
<tr>
<td id="leftcol">{{item.level}}</td>
{% if item.replaced %}
<td class="leftcol_slim">{{item.level}}</td>
<td class="middlecol warning_icon_replaced"><img height="35px" src="/static/warning_cmip6_green_transparent.png"></td>
{% else %}
<td class="leftcol">{{item.level}}</td>
{% endif %}
<td>
{{ item.title }}
{% if item.version %}
(version {{ item.version }})
{% endif %}
<br/><a href="http://hdl.handle.net/{{ item.handle }}/">hdl:{{ item.handle }}</a>
{% if item.replaced %}
<br/><span class="attention">Attention, this {{item.level}} was replaced by a newer version!*</span>
{% endif %}
<!--{% if item.replaced %}
</td><td class="replaced"><span class="attention">Attention, this {{item.level}} was replaced by a newer version!*</span>
{% endif %}-->
</td>
</tr>
{% endfor %}
{% if any_parent_replaced %}
<tr class="note">
<td colspan="2"><span class="note">
<strong>* Note:</strong> If a dataset was replaced by a newer version, it is possible that there was an issue with this file, but not necessarily. It is also possible that the dataset was replaced due to problems in other files or due to lacking files. Please refer to the dataset's errata description to get more information. You can find information on the errata on the dataset's landing page or at the ESGF Errata Service.</span>
<td colspan="3"><span class="note">
<img height="14px" src="/static/warning_cmip6_green_transparent.png"><strong>&nbsp;This dataset was replaced by a newer version.</strong> If a dataset containing this file was replaced by a newer version, it is possible that there was an issue with this file, but not necessarily. It is also possible that the dataset was replaced due to problems in other files or due to lacking files. Please refer to the dataset's errata description to get more information. You can find information on the errata on the dataset's landing page or at the ESGF Errata Service.</span>
</td>
</tr>
{% endif %}
......
......@@ -32,7 +32,7 @@
<table>
{% for key,value in values.items %}
<tr>
<td id="leftcol">{{key}}</td>
<td class="leftcol">{{key}}</td>
<td>{{value}}</td>
</tr>
{% endfor %}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment