- tethys favicon also in oai: oai2_style.xslt
- zenodo search: adapted search_style.css, App.vue, dataservice.ts, vs-results.vue
This commit is contained in:
parent
8208558e8c
commit
578021e07e
113
public/css/search_style.css
vendored
113
public/css/search_style.css
vendored
|
@ -17,14 +17,87 @@ section.search {
|
|||
}
|
||||
|
||||
|
||||
/* zenodo */
|
||||
.label-success {
|
||||
background-color: #5cb85c;
|
||||
}
|
||||
.label-default {
|
||||
background-color: #777;
|
||||
}
|
||||
.label-info {
|
||||
background-color: #6aa3d5;
|
||||
}
|
||||
.label {
|
||||
display: inline-block;
|
||||
padding: .2em .12em .3em;
|
||||
font-size: 75%;
|
||||
color: #fff;
|
||||
border-radius: .25em;
|
||||
margin-right:1.25em;
|
||||
/* margin-left: 10px; */
|
||||
}
|
||||
/* .record-elem .h4, record-elem h4 {
|
||||
font-size: 18px;
|
||||
} */
|
||||
.record-elem p a {
|
||||
color: #000;
|
||||
}
|
||||
/* .record-elem h4 a {
|
||||
color: #000;
|
||||
} */
|
||||
a.ng-binding {
|
||||
cursor: pointer;
|
||||
}
|
||||
.record-elem h4 a {
|
||||
cursor: pointer;
|
||||
color: #000;
|
||||
text-decoration: none;
|
||||
font-weight: bold;
|
||||
/* margin-left: 10px; */
|
||||
font-size: 16px;
|
||||
}
|
||||
.record-elem h4 a:hover {
|
||||
color: #777;
|
||||
text-decoration: none;
|
||||
}
|
||||
/* .search-detail a:hover {
|
||||
color: rgb(0, 128, 0);
|
||||
} */
|
||||
.record-elem .h4, .record-elem h4 {
|
||||
font-size: 16px;
|
||||
letter-spacing: .05em;
|
||||
}
|
||||
.record-detail h1, .record-detail p,
|
||||
.record-elem h4,
|
||||
.record-elem p, .well {
|
||||
word-wrap: break-word;
|
||||
}
|
||||
.record-elem p span {
|
||||
color: #000;
|
||||
font-size: 14px;
|
||||
}
|
||||
|
||||
.post {
|
||||
position: relative;
|
||||
min-height: 1px;
|
||||
padding-left: 15px;
|
||||
padding-right: 15px;
|
||||
|
||||
/* Seasrch items */
|
||||
box-sizing: border-box;
|
||||
margin-bottom:10px;
|
||||
margin-top: 15px;
|
||||
|
||||
}
|
||||
.record-elem{
|
||||
|
||||
border-top: 1px solid rgb(238, 238, 238);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
.search-items {
|
||||
/* Search items */
|
||||
/* .search-items {
|
||||
list-style: none;
|
||||
width: 100%;
|
||||
display: inline-block;
|
||||
|
@ -33,8 +106,6 @@ section.search {
|
|||
position: relative;
|
||||
overflow: hidden;
|
||||
height: 360px;
|
||||
|
||||
/* important because we need to overwrite the default skeleton */
|
||||
margin: 0!important;
|
||||
width: 50%;
|
||||
border: 10px solid white;
|
||||
|
@ -50,51 +121,23 @@ section.search {
|
|||
width: auto;
|
||||
height: 100%;
|
||||
display: block;
|
||||
|
||||
}
|
||||
} */
|
||||
|
||||
/* Work detail */
|
||||
.search-detail {
|
||||
/* .search-detail {
|
||||
position: absolute;
|
||||
top: 0; bottom: 0; left: 0; right: 0;
|
||||
transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1) 0s;
|
||||
|
||||
align-items: center;
|
||||
/* box-shadow: rgba(0, 0, 0, 0.12) 0px 1px 3px, rgba(0, 0, 0, 0.24) 0px 1px 2px; */
|
||||
/* box-shadow: 3px 3px red, -1em 0 0.4em olive; */
|
||||
box-shadow: inset rgba(0, 0, 0, 0.12) 0px 1px 3px, rgba(0, 0, 0, 0.24) 0px 1px 2px;
|
||||
opacity: 1;
|
||||
border: 1px solid rgb(238, 238, 238);
|
||||
box-sizing: border-box;
|
||||
min-height: 300px;
|
||||
/* background: rgba(0,0,0,.75); */
|
||||
/* color: white; */
|
||||
font-size: 16px;
|
||||
|
||||
padding:20px;
|
||||
} */
|
||||
|
||||
}
|
||||
.search-detail a {
|
||||
cursor: pointer;
|
||||
color: mediumseagreen;
|
||||
text-decoration: none;
|
||||
font-weight: bold;
|
||||
margin-left: 20px;
|
||||
font-size: 16px;
|
||||
}
|
||||
.search-detail a:hover {
|
||||
color: rgb(0, 128, 0);
|
||||
}
|
||||
.search-detail h3 {
|
||||
font-size: 16px;
|
||||
letter-spacing: .05em;
|
||||
}
|
||||
.search-detail p {
|
||||
font-size: 15px;
|
||||
/* text-transform: capitalize; */
|
||||
/* padding-left: 20px;
|
||||
padding-right: 20px; */
|
||||
}
|
||||
|
||||
|
||||
/* Larger than mobile */
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -162,6 +162,14 @@ p.intro {
|
|||
<head>
|
||||
<title>TETHYS OAI 2.0 Request Results</title>
|
||||
<style><xsl:call-template name="style"/></style>
|
||||
<!-- Favicon
|
||||
–––––––––––––––––––––––––––––––––––––––––––––––––– -->
|
||||
<link rel="apple-touch-icon" sizes="180x180" href="/images/favicon/apple-touch-icon.png"/>
|
||||
<link rel="icon" type="image/png" sizes="32x32" href="/images/favicon/favicon-32x32.png"/>
|
||||
<link rel="icon" type="image/png" sizes="16x16" href="/images/favicon/favicon-16x16.png"/>
|
||||
<link rel="manifest" href="/images/favicon/site.webmanifest"/>
|
||||
<link rel="mask-icon" href="/images/favicon/safari-pinned-tab.svg" color="#5bbad5"/>
|
||||
<link rel="shortcut icon" href="/images/favicon/favicon.ico"/>
|
||||
</head>
|
||||
<body>
|
||||
<h1>TETHYS OAI 2.0 Request Results</h1>
|
||||
|
@ -219,7 +227,6 @@ p.intro {
|
|||
|
||||
|
||||
<!-- ERROR -->
|
||||
|
||||
<xsl:template match="/oai:OAI-PMH/oai:error">
|
||||
<table class="values">
|
||||
<tr><td class="key">Error Code</td>
|
||||
|
@ -229,7 +236,6 @@ p.intro {
|
|||
</xsl:template>
|
||||
|
||||
<!-- IDENTIFY -->
|
||||
|
||||
<xsl:template match="/oai:OAI-PMH/oai:Identify">
|
||||
<table class="values">
|
||||
<tr><td class="key">Repository Name</td>
|
||||
|
@ -258,7 +264,6 @@ p.intro {
|
|||
<!--
|
||||
Identify / Unsupported Description
|
||||
-->
|
||||
|
||||
<xsl:template match="oai:description/*" priority="-100">
|
||||
<h2>Unsupported Description Type</h2>
|
||||
<p>The XSL currently does not support this type of description.</p>
|
||||
|
@ -271,7 +276,6 @@ p.intro {
|
|||
<!--
|
||||
Identify / OAI-Identifier
|
||||
-->
|
||||
|
||||
<xsl:template match="id:oai-identifier" xmlns:id="http://www.openarchives.org/OAI/2.0/oai-identifier">
|
||||
<h2>OAI-Identifier</h2>
|
||||
<table class="values">
|
||||
|
@ -290,7 +294,6 @@ p.intro {
|
|||
<!--
|
||||
Identify / EPrints
|
||||
-->
|
||||
|
||||
<xsl:template match="ep:eprints" xmlns:ep="http://www.openarchives.org/OAI/1.1/eprints">
|
||||
<h2>EPrints Description</h2>
|
||||
<h3>Content</h3>
|
||||
|
@ -328,7 +331,6 @@ p.intro {
|
|||
<!--
|
||||
Identify / Friends
|
||||
-->
|
||||
|
||||
<xsl:template match="fr:friends" xmlns:fr="http://www.openarchives.org/OAI/2.0/friends/">
|
||||
<h2>Friends</h2>
|
||||
<ul>
|
||||
|
@ -346,7 +348,6 @@ p.intro {
|
|||
<!--
|
||||
Identify / Branding
|
||||
-->
|
||||
|
||||
<xsl:template match="br:branding" xmlns:br="http://www.openarchives.org/OAI/2.0/branding/">
|
||||
<h2>Branding</h2>
|
||||
<xsl:apply-templates select="br:collectionIcon"/>
|
||||
|
@ -382,7 +383,6 @@ p.intro {
|
|||
<!--
|
||||
Identify / Gateway
|
||||
-->
|
||||
|
||||
<xsl:template match="gw:gateway" xmlns:gw="http://www.openarchives.org/OAI/2.0/gateway/x">
|
||||
<h2>Gateway Information</h2>
|
||||
<table class="values">
|
||||
|
@ -409,27 +409,23 @@ p.intro {
|
|||
|
||||
|
||||
<!-- GetRecord -->
|
||||
|
||||
<xsl:template match="oai:GetRecord">
|
||||
<xsl:apply-templates select="oai:record" />
|
||||
</xsl:template>
|
||||
|
||||
<!-- ListRecords -->
|
||||
|
||||
<xsl:template match="oai:ListRecords">
|
||||
<xsl:apply-templates select="oai:record" />
|
||||
<xsl:apply-templates select="oai:resumptionToken" />
|
||||
</xsl:template>
|
||||
|
||||
<!-- ListIdentifiers -->
|
||||
|
||||
<xsl:template match="oai:ListIdentifiers">
|
||||
<xsl:apply-templates select="oai:header" />
|
||||
<xsl:apply-templates select="oai:resumptionToken" />
|
||||
</xsl:template>
|
||||
|
||||
<!-- ListSets -->
|
||||
|
||||
<xsl:template match="oai:ListSets">
|
||||
<xsl:apply-templates select="oai:set" />
|
||||
<xsl:apply-templates select="oai:resumptionToken" />
|
||||
|
@ -445,7 +441,6 @@ p.intro {
|
|||
</xsl:template>
|
||||
|
||||
<!-- ListMetadataFormats -->
|
||||
|
||||
<xsl:template match="oai:ListMetadataFormats">
|
||||
<xsl:choose>
|
||||
<xsl:when test="$identifier">
|
||||
|
@ -484,7 +479,6 @@ p.intro {
|
|||
</xsl:template>
|
||||
|
||||
<!-- record object -->
|
||||
|
||||
<xsl:template match="oai:record">
|
||||
<h2 class="oaiRecordTitle">OAI Record: <xsl:value-of select="oai:header/oai:identifier"/></h2>
|
||||
<div class="oaiRecord">
|
||||
|
@ -512,7 +506,6 @@ p.intro {
|
|||
</xsl:if>
|
||||
</xsl:template>
|
||||
|
||||
|
||||
<xsl:template match="oai:about">
|
||||
<p>"about" part of record container not supported by the XSL</p>
|
||||
</xsl:template>
|
||||
|
@ -524,11 +517,7 @@ p.intro {
|
|||
</div>
|
||||
</xsl:template>
|
||||
|
||||
|
||||
|
||||
|
||||
<!-- oai setSpec object -->
|
||||
|
||||
<xsl:template match="oai:setSpec">
|
||||
<tr><td class="key">setSpec</td>
|
||||
<td class="value"><xsl:value-of select="."/>
|
||||
|
@ -537,10 +526,7 @@ p.intro {
|
|||
</td></tr>
|
||||
</xsl:template>
|
||||
|
||||
|
||||
|
||||
<!-- oai resumptionToken -->
|
||||
|
||||
<xsl:template match="oai:resumptionToken">
|
||||
<p>There are more results.</p>
|
||||
<table class="values">
|
||||
|
@ -552,7 +538,6 @@ p.intro {
|
|||
</xsl:template>
|
||||
|
||||
<!-- unknown metadata format -->
|
||||
|
||||
<xsl:template match="oai:metadata/*" priority='-100'>
|
||||
<h3>Unknown Metadata Format</h3>
|
||||
<div class="xmlSource">
|
||||
|
@ -561,7 +546,6 @@ p.intro {
|
|||
</xsl:template>
|
||||
|
||||
<!-- oai_dc record -->
|
||||
|
||||
<xsl:template match="oai_dc:dc" xmlns:oai_dc="http://www.openarchives.org/OAI/2.0/oai_dc/" >
|
||||
<div class="dcdata">
|
||||
<h3>Dublin Core Metadata (oai_dc)</h3>
|
||||
|
@ -634,7 +618,6 @@ p.intro {
|
|||
<tr><td class="key">Rights Management</td><td class="value"><xsl:value-of select="."/></td></tr></xsl:template>
|
||||
|
||||
<!-- XML Pretty Maker -->
|
||||
|
||||
<xsl:template match="node()" mode='xmlMarkup'>
|
||||
<div class="xmlBlock">
|
||||
<<span class="xmlTagName"><xsl:value-of select='name(.)' /></span><xsl:apply-templates select="@*" mode='xmlMarkup'/>><xsl:apply-templates select="node()" mode='xmlMarkup' /></<span class="xmlTagName"><xsl:value-of select='name(.)' /></span>>
|
||||
|
@ -670,4 +653,3 @@ p.intro {
|
|||
</xsl:template>
|
||||
|
||||
</xsl:stylesheet>
|
||||
|
||||
|
|
|
@ -40,7 +40,7 @@
|
|||
<span v-if="value && value.length > 0">{{ value.join(', ') }}</span>
|
||||
</a>
|
||||
</div> -->
|
||||
<div class="twelve columns">
|
||||
<div class="twelve columns resultheader">
|
||||
<span class="active-filter-items" v-for="(values, key, index) in activeFilterCategories" :key="index">
|
||||
<active-facet-category :data="values" :categoryName="key" @clearFacetCategory="onClearFacetCategory"></active-facet-category>
|
||||
</span>
|
||||
|
@ -84,6 +84,9 @@ export default App;
|
|||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
.resultheader {
|
||||
padding-left: 4%;
|
||||
}
|
||||
#app {
|
||||
color: #56b983;
|
||||
}
|
||||
|
|
|
@ -184,7 +184,7 @@ export default class App extends Vue {
|
|||
this.loaded = true;
|
||||
}
|
||||
|
||||
getParameterByName(name: string, url?: string) {
|
||||
private getParameterByName(name: string, url?: string) {
|
||||
if (!url) url = window.location.href;
|
||||
name = name.replace(/[\[\]]/g, "\\$&");
|
||||
var regex = new RegExp("[?&]" + name + "(=([^&#]*)|&|#|$)"),
|
||||
|
|
|
@ -3,7 +3,7 @@ import axios from "axios";
|
|||
var SOLR_CONFIG = {
|
||||
"server": "https://arcticdata.io/metacat/d1/mn/v2/query/solr?", // Solr server
|
||||
"filter": "knb-lter-bnz", // Filter results for an organization or user
|
||||
"limit": 4, // Max number of results to retrieve per page
|
||||
"limit": 10, // Max number of results to retrieve per page
|
||||
"resultsElementId": "searchResults", // Element to contain results
|
||||
"urlElementId": "searchUrl", // Element to display search URL
|
||||
"countElementId": "resultCount", // Element showing number of results
|
||||
|
@ -28,7 +28,7 @@ export default {
|
|||
"title_output",
|
||||
"title_additional",
|
||||
"author",
|
||||
"subject"].toString();
|
||||
"subject", "doctype"].toString();
|
||||
var limit = "&rows=" + SOLR_CONFIG["limit"];
|
||||
// var limit = solrConfig.limit;
|
||||
|
||||
|
@ -86,7 +86,7 @@ export default {
|
|||
"title_output",
|
||||
"title_additional",
|
||||
"author",
|
||||
"subject"].toString();
|
||||
"subject", "doctype"].toString();
|
||||
|
||||
|
||||
//var dismaxFields = "title^3 abstract^2 subject^1";
|
||||
|
|
|
@ -17,25 +17,34 @@
|
|||
</div>
|
||||
</div> -->
|
||||
|
||||
<section class="result-list-container">
|
||||
<div class="row">
|
||||
<ul class="search-items isotope js-isotope u-cf">
|
||||
<li v-for="document in results" :key="document.id" class="six columns post">
|
||||
<div class="search-detail">
|
||||
<div>
|
||||
<a
|
||||
v-bind:href="'dataset/' + document.id"
|
||||
>{{ document.title_output }}</a>
|
||||
</div>
|
||||
<section class="normal result-list-container">
|
||||
|
||||
<div v-for="document in results" :key="document.id" class="row record-elem">
|
||||
<div class="twelve columns post">
|
||||
|
||||
<span class="label label-info" data-container="div" data-title="Publication date">
|
||||
{{ convert(document.server_date_published) }}
|
||||
</span>
|
||||
<span class="label label-default ng-binding">{{ document.doctype }}</span>
|
||||
<span class="label label-success titlecase">Open Access</span>
|
||||
|
||||
<p v-if="document.title_additional && document.title_additional.length > 0">
|
||||
<em>Additional Title:{{ document.title_additional.join(', ') }}</em>
|
||||
</p>
|
||||
|
||||
<div v-if="document.author && document.author.length > 0">
|
||||
<em>Author: {{ document.author.join(', ') }}</em>
|
||||
</div>
|
||||
<h4>
|
||||
<a target="_self" v-bind:href="'dataset/' + document.id" class="ng-binding">
|
||||
{{ document.title_output }}
|
||||
</a>
|
||||
</h4>
|
||||
|
||||
<p>
|
||||
<span v-if="document.author && document.author.length > 0" v-for="author in document.author">
|
||||
<!-- <span>Author: {{ document.author.join(', ') }}</span> -->
|
||||
<span>{{ author }}; </span>
|
||||
</span>
|
||||
|
||||
|
||||
<!-- <p v-if="document.title_additional && document.title_additional.length > 0">
|
||||
<span>Additional Title:{{ document.title_additional.join(', ') }}</span>
|
||||
</p> -->
|
||||
|
||||
<p class="clamped clamped-2">
|
||||
<span class="text">
|
||||
|
@ -44,14 +53,19 @@
|
|||
<span class="fill"></span>
|
||||
</span>
|
||||
</p>
|
||||
<div class="css-subject" v-if="document.subject && document.subject.length > 0">
|
||||
<div v-for="(item, index) in document.subject" :key="index" class="css-keyword">#{{ item }}</div>
|
||||
<!-- <div class="css-keyword">#graphql</div> -->
|
||||
|
||||
<!-- <div class="css-subject" v-if="document.subject && document.subject.length > 0"> -->
|
||||
<span class="label label-success titlecase" v-for="(item, index) in document.subject" :key="index">
|
||||
#{{ item }}
|
||||
</span>
|
||||
<!-- <p>
|
||||
<small class="text-muted hidden-xs ng-binding">
|
||||
Uploaded on March 15, 2019
|
||||
</small>
|
||||
</p> -->
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</section>
|
||||
</div>
|
||||
</template>
|
||||
|
@ -60,4 +74,3 @@
|
|||
import VgResults from "./vs-results-class";
|
||||
export default VgResults;
|
||||
</script>
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user