better corpus list display
This commit is contained in:
+69
-1
@@ -55,6 +55,9 @@ header[role="banner"]{
|
|||||||
}
|
}
|
||||||
li>span,li>a{
|
li>span,li>a{
|
||||||
font-size: 0.9em;
|
font-size: 0.9em;
|
||||||
|
color: $bleuroi;
|
||||||
|
text-transform: uppercase;
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -97,6 +100,19 @@ section[role="main-content"]{
|
|||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
flex-basis: percentage(2 / ( $default_sum - 6) );
|
flex-basis: percentage(2 / ( $default_sum - 6) );
|
||||||
padding-right: $default_gap;
|
padding-right: $default_gap;
|
||||||
|
@include fontsans;
|
||||||
|
|
||||||
|
h1{
|
||||||
|
color: $bleuroi;
|
||||||
|
}
|
||||||
|
p{
|
||||||
|
font-size: 0.882em;
|
||||||
|
line-height: 1.2;
|
||||||
|
}
|
||||||
|
span{
|
||||||
|
color:$rouge;
|
||||||
|
font-size:0.693em;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
// filets decoratif
|
// filets decoratif
|
||||||
&:before, &:after{
|
&:before, &:after{
|
||||||
@@ -132,12 +148,64 @@ section[role="main-content"]{
|
|||||||
article.item{
|
article.item{
|
||||||
margin: 2em 0 0;
|
margin: 2em 0 0;
|
||||||
header h1{
|
header h1{
|
||||||
font-size: 1.323em;
|
font-size: 1.512em;
|
||||||
color: $bleuroi;
|
color: $bleuroi;
|
||||||
font-weight: 400;
|
font-weight: 400;
|
||||||
margin:0;
|
margin:0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
ul.item-list{
|
||||||
|
li{
|
||||||
|
margin: 0 0 2em 0;
|
||||||
|
header{
|
||||||
|
h2{
|
||||||
|
margin:0.4em 0;
|
||||||
|
font-size: 1.512em;
|
||||||
|
color: $bleuroi;
|
||||||
|
font-weight: 400;
|
||||||
|
}
|
||||||
|
h3{
|
||||||
|
margin:0.2em 0;
|
||||||
|
@include fontsans;
|
||||||
|
font-size: 0.753em;
|
||||||
|
font-weight: 500;
|
||||||
|
}
|
||||||
|
h4{
|
||||||
|
margin:0.1em 0;
|
||||||
|
font-weight: 300;
|
||||||
|
@include fontsans;
|
||||||
|
font-size: 0.753em;
|
||||||
|
&.editions-quantity{
|
||||||
|
color: $rouge;
|
||||||
|
&:after{
|
||||||
|
content: ">>";
|
||||||
|
margin:0 0 0 0.5em;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
section.editions{
|
||||||
|
div.editions{
|
||||||
|
ol{
|
||||||
|
padding:0;
|
||||||
|
li{
|
||||||
|
margin:0.7em 1em;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
ul {
|
||||||
|
li{
|
||||||
|
margin:0;
|
||||||
|
h3{
|
||||||
|
margin: 0.5em 0;
|
||||||
|
font-weight: 400;
|
||||||
|
font-size: 1em;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#corpus{
|
#corpus{
|
||||||
|
|||||||
@@ -4,8 +4,15 @@
|
|||||||
// @import '../fonts/notosans/notosans-condensed.css';
|
// @import '../fonts/notosans/notosans-condensed.css';
|
||||||
// @import '../fonts/notosans/notosans-extracondensed.css';
|
// @import '../fonts/notosans/notosans-extracondensed.css';
|
||||||
|
|
||||||
body{
|
@mixin fontsans {
|
||||||
|
font-family: "noto_sans";
|
||||||
|
}
|
||||||
|
@mixin fontserif {
|
||||||
font-family: 'libertinus_serif';
|
font-family: 'libertinus_serif';
|
||||||
|
}
|
||||||
|
|
||||||
|
body{
|
||||||
|
@include fontserif;
|
||||||
font-weight: 400;
|
font-weight: 400;
|
||||||
|
|
||||||
// font-family: 'noto_sans';
|
// font-family: 'noto_sans';
|
||||||
@@ -18,5 +25,5 @@ body{
|
|||||||
#search,
|
#search,
|
||||||
footer[role="tools"] .row>header,
|
footer[role="tools"] .row>header,
|
||||||
footer[role="tools"] .row>nav{
|
footer[role="tools"] .row>nav{
|
||||||
font-family: "noto_sans";
|
@include fontsans;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
<ul>
|
<ul>
|
||||||
<li><router-link to="/corpus">Corpus</router-link></li>
|
<li><router-link to="/corpus">Corpus</router-link></li>
|
||||||
<li>
|
<li>
|
||||||
<span>Index</span>
|
<span>Indexs</span>
|
||||||
<ul>
|
<ul>
|
||||||
<li><router-link to="/nominum">Personnes</router-link></li>
|
<li><router-link to="/nominum">Personnes</router-link></li>
|
||||||
<li><router-link to="/locorum">Lieux</router-link></li>
|
<li><router-link to="/locorum">Lieux</router-link></li>
|
||||||
|
|||||||
@@ -7,9 +7,17 @@
|
|||||||
|
|
||||||
<ul v-if="editionslist.length" class="item-list">
|
<ul v-if="editionslist.length" class="item-list">
|
||||||
<li v-for="(corpus,index) in editionslist" :key="index">
|
<li v-for="(corpus,index) in editionslist" :key="index">
|
||||||
<h2>{{ corpus.meta.author }}</h2>
|
<header>
|
||||||
<ul>
|
<h2>{{ corpus.author.title }}</h2>
|
||||||
<li v-for="text in corpus.content" :key="text.uuid">
|
<h3>{{ corpus.author.date }}</h3>
|
||||||
|
<section class="editions">
|
||||||
|
<h4 class="editions-quantity">{{ corpus.author.editionsQuantity }}</h4>
|
||||||
|
<div v-if="corpus.author.editions" class="editions" v-html="corpus.author.editions"/>
|
||||||
|
</section>
|
||||||
|
<h4 class="texts-quantity">{{ corpus.author.textsQuantity }}</h4>
|
||||||
|
</header>
|
||||||
|
<ul class="texts-list">
|
||||||
|
<li v-for="text in corpus.editions.content" :key="text.uuid">
|
||||||
<h3>
|
<h3>
|
||||||
<a
|
<a
|
||||||
:href="text.url"
|
:href="text.url"
|
||||||
|
|||||||
+13
-10
@@ -33,11 +33,11 @@ export default {
|
|||||||
console.log('getCorpuses authors data', data)
|
console.log('getCorpuses authors data', data)
|
||||||
commit('setAuthors', data.content)
|
commit('setAuthors', data.content)
|
||||||
// get the texts list for each corpus (aka author)
|
// get the texts list for each corpus (aka author)
|
||||||
let authorsUuids = []
|
// let authorsUuids = []
|
||||||
for (let author of data.content) {
|
// for (let author of data.content) {
|
||||||
authorsUuids.push(author.uuid)
|
// authorsUuids.push(author.uuid)
|
||||||
}
|
// }
|
||||||
dispatch('getEditionsList', authorsUuids)
|
dispatch('getEditionsList', data.content)
|
||||||
.then((editionslist) => {
|
.then((editionslist) => {
|
||||||
console.log('all texts returned: editionslist', editionslist)
|
console.log('all texts returned: editionslist', editionslist)
|
||||||
commit('setEditionslist', editionslist)
|
commit('setEditionslist', editionslist)
|
||||||
@@ -58,16 +58,19 @@ export default {
|
|||||||
})
|
})
|
||||||
},
|
},
|
||||||
// get editionslist
|
// get editionslist
|
||||||
getEditionsList ({ dispatch, commit, state }, authorsUuids) {
|
getEditionsList ({ dispatch, commit, state }, authors) {
|
||||||
return Promise.all(authorsUuids.map(function (uuid) {
|
return Promise.all(authors.map(function (author) {
|
||||||
return REST.get(`/corpus/` + uuid, {})
|
return REST.get(`/corpus/` + author.uuid, {})
|
||||||
.then(({ data }) => {
|
.then(({ data }) => {
|
||||||
console.log('corpus getEditionsList REST: data', data)
|
console.log('corpus getEditionsList REST: author, data', author, data)
|
||||||
// work arround
|
// work arround
|
||||||
if (!Array.isArray(data.content)) {
|
if (!Array.isArray(data.content)) {
|
||||||
data.content = [data.content]
|
data.content = [data.content]
|
||||||
}
|
}
|
||||||
return data
|
return {
|
||||||
|
author: author,
|
||||||
|
editions: data
|
||||||
|
}
|
||||||
})
|
})
|
||||||
.catch((error) => {
|
.catch((error) => {
|
||||||
console.warn('Issue with getEditionsList', error)
|
console.warn('Issue with getEditionsList', error)
|
||||||
|
|||||||
Reference in New Issue
Block a user