Commit b2ee65fc authored by Maxime Chaillet's avatar Maxime Chaillet

Homogenize white spaces in experimental report and experimenal data boxes

parent ee1c3154
......@@ -86,6 +86,10 @@ body {
padding-top:15px;
}
.padding-top-5 {
padding-top:5px;
}
.padding-bottom-15 {
padding-bottom:15px;
}
......@@ -186,7 +190,7 @@ label {
.scroll-box {
overflow-y: auto;
overflow-x: hidden;
height: 140px;
height: 130px;
}
/* ######################## For welcome page ############# */
......
This diff is collapsed.
This source diff could not be displayed because it is too large. You can view the blob instead.
This diff is collapsed.
......@@ -37,7 +37,7 @@ DOIController.prototype.isValidDOIData = function(doiData) {
DOIController.prototype.getData = function(doi) {
var _this = this;
this.view.setDOI(doi);
this.view.setDOIInTopBanner(doi);
//this.view.setDOILink(_this.doiServer + doi);
if (this.hasAcceptedPrefix(doi)) {
......@@ -66,6 +66,7 @@ DOIController.prototype.getData = function(doi) {
var doiData = new DoiData();
doiData.title = data.title;
doiData.doi = data.doi.toUpperCase();
doiData.dataciteLink = _this.doiServer + doi;
doiData.publisher = data.publisher;
doiData.creator = data.creator;
......
......@@ -19,10 +19,10 @@ DOIView.prototype.setLoading = function( message ) {
};
/**
* Set the doi prefix/suffix text in the doi landing page.
* Set the doi prefix/suffix text in the top banner of the doi landing page. This is done before the template is rendered.
*
*/
DOIView.prototype.setDOI = function( doiCode ) {
DOIView.prototype.setDOIInTopBanner = function( doiCode ) {
$( "#doiValue" ).text( "DOI > " + doiCode.toUpperCase() );
// $( "#doiBadge" ).html(
// "<span class='doiBadge borderRadius-5 fontSize-20'> <a id='doiLink' href=''>" +
......@@ -166,8 +166,8 @@ DOIView.prototype.setDataAccessMessage = function( doiData ) {
if ( doiData.accessibility === "Open access" ) {
return "The data can be accessed by clicking on the link below";
} else if ( doiData.accessibility === "Restricted access" ) {
return "<p> The data is under embargo until <b>" + doiData.publiclyAccessibleYear + "</b> but could be released earlier." +
" Currently, it is only accessible to proposal team members. </p>";
return "The data is under embargo until <b>" + doiData.publiclyAccessibleYear + "</b> but could be released earlier." +
" Currently, it is only accessible to proposal team members.";
}
};
<div class="row margin-left-0 margin-right-0">
{@eq key=data.resourceTypeGeneral value="Dataset"}
<div class="col"> </div>
<div class="col-auto padding-right-2 padding-left-2">
<span class="badge badge-secondary font-1p4rem"> Dataset </span>
</div>
{/eq}
<div class="row margin-left-0 margin-right-0">
{@eq key=data.resourceType value="Experiment Session"}
{@eq key=data.resourceType value="Experiment Session"}
<div class="col-auto padding-right-2 padding-left-2">
<span class="badge badge-secondary font-1p4rem " > Session </span>
</div>
{/eq}
{/eq}
<div class="col"> </div>
{@eq key=data.resourceTypeGeneral value="Dataset"}
<div class="col-auto padding-right-2 padding-left-2">
<span class="badge badge-secondary font-1p4rem"> Dataset </span>
</div>
{/eq}
{@eq key=data.accessibility value="Open access"}
{@eq key=data.accessibility value="Open access"}
<div class="col-auto padding-right-2 padding-left-2">
<span class="badge badge-success font-1p4rem "> Open access </span>
</div>
{/eq}
{/eq}
{@eq key=data.accessibility value="Restricted access"}
{@eq key=data.accessibility value="Restricted access"}
<div class="col-auto padding-right-2 padding-left-2">
<span class="badge badge-warning font-1p4rem "> Restricted access </span>
</div>
{/eq}
{/eq}
</div>
\ No newline at end of file
</div>
\ No newline at end of file
......@@ -3,31 +3,46 @@
</div>
<div class="card-body padding10">
{?data}
{@eq key=data.length value=1}
<p> <b> One </b> report has been found for this proposal. </p>
{?data}
{@eq key=data.length value=1}
<p class="card-text"> <b> One </b> report has been found for this proposal. </p>
</div>
<div class="card-footer">
<button type="button" class="btn btn-primary btn-lg btn-block" onclick="javascript:(function(){ var expRep = new ExperimentalReportController(); expRep.openFileInNewTab('{data[0]}'); })()" > <span class="fa fa-download whiteFont"></span> {data[0]} </button>
</div>
<div class="card-body">
<button type="button" class="btn btn-primary btn-lg btn-block" onclick="javascript:(function(){ var expRep = new ExperimentalReportController(); expRep.openFileInNewTab('{data[0]}'); })()" > <span class="fa fa-download whiteFont"></span> {data[0]} </button>
</div>
{/eq}
{@gt key=data.length value=1}
<p> In total, <b> {data.length} </b> reports have been found for this proposal: </p>
<div class="scroll-box">
{#data}
<div class="row">
<div class="col-1"> </div>
<div class="col-10 padding-bottom-10">
<button type="button" class="btn btn-primary btn-lg btn-block" onclick="javascript:(function(){ var expRep = new ExperimentalReportController(); expRep.openFileInNewTab('{.}'); })()" > <span class="fa fa-download whiteFont"></span> <span class="whitefont"> {.}</span> </button>
{@gt key=data.length value=1}
<p class="card-text"> In total, <b> {data.length} </b> reports have been found for this proposal: </p>
</div>
<div class="card-body">
<div class="scroll-box">
{#data}
{@sep}
<div class="row">
<div class="col-1"> </div>
<div class="col-10 padding-bottom-10">
<button type="button" class="btn btn-primary btn-lg btn-block" onclick="javascript:(function(){ var expRep = new ExperimentalReportController(); expRep.openFileInNewTab('{.}'); })()" > <span class="fa fa-download whiteFont"></span> <span class="whitefont"> {.}</span> </button>
</div>
<div class="col-1"> </div>
</div>
{/sep}
{@last}
<div class="row">
<div class="col-1"> </div>
<div class="col-10">
<button type="button" class="btn btn-primary btn-lg btn-block" onclick="javascript:(function(){ var expRep = new ExperimentalReportController(); expRep.openFileInNewTab('{.}'); })()" > <span class="fa fa-download whiteFont"></span> <span class="whitefont"> {.}</span> </button>
</div>
<div class="col-1"> </div>
</div>
{/last}
{/data}
</div>
</div>
<div class="col-1"> </div>
</div>
{/data}
</div>
{/gt}
</div>
{:else}
<p> There is currently no experimental report. </p>
{/gt}
{:else}
<p class="card-text"> There is currently no experimental report. </p>
</div>
{/data}
......
<div class="container-fluid">
<div class="row padding-top-15">
<div class="col-9">
<div class="col-12 col-md-9">
<div class="row">
<div class="col-12">
<div id="badges"> </div>
......@@ -23,16 +23,21 @@
</div>
</div>
</div>
<div class="col-3">
<div class="col-12 col-md-3">
<div class="card">
<div class="card-body">
<div class="card-text">
<label> DOI </label>
<div>
<div class="padding-left-15">
<span class="doiBadge borderRadius-5 font-1p4rem">
<a id="doiLink" href=""> {data.doi} </a>
<a id="doiLink" href={data.dataciteLink}> {data.doi} </a>
</span>
</div>
<label class="padding-top-5"> Licence (for files) </label>
<div class="padding-left-15">
<p> <a href="https://creativecommons.org/licenses/by/4.0/"> Creative Common Attribution 4.0 </a> </p>
</div>
</div>
</div>
</div>
......@@ -140,7 +145,7 @@
<div class="card-body padding10">
<p class="card-text" >{data.accessMessage|s}</p>
</div>
<div class="card-footer">
<div class="card-body">
<div class="row">
<div class="col-1"> </div>
<div class="col-10">
......@@ -161,11 +166,7 @@
<div class="col-12">
<div class="myBorder-left">
<label class="greyGradientToRight padding-left-10 padding-right-20"> Citation </label>
<a data-toggle="collapse" href="#citation" role="button" aria-expanded="false" aria-controls="citation">
&nbsp; +/-
</a>
<div class="padding-left-25 collapse" id="citation">
<div class="padding-left-25">
<p> Below is the recommended format for citing this work in a research publication.</p>
<div class="padding-left-25">
<cite> {data.citation|s} </cite>
......
Markdown is supported
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