-
Notifications
You must be signed in to change notification settings - Fork 2
/
book-info.vue
74 lines (73 loc) · 2.51 KB
/
book-info.vue
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
<template lang="pug">
div(itemscope='', itemtype='https://schema.org/Book')
h2 Informácie o publikácii
dl.cl--dl
dt Názov
dd(itemprop='name') {{item.title.value}}
dt Autor
dd(itemprop='author', itemtype='https://schema.org/Person', itemscope='')
span(itemprop='name') {{item.author.value}}
dt Ilustrácie
dd(itemprop='illustrator', itemtype='https://schema.org/Person', itemscope='')
span(itemprop='name') {{item.illustrator.value}}
dt Jazyková úprava
dd(itemprop='editor', itemtype='https://schema.org/Person', itemscope='')
span(itemprop='name') {{item.language_editor.value}}
dt(v-if='item.technical_editor.value!=""') Technický redaktor
dd(v-if='item.technical_editor.value!=""')
span {{item.technical_editor.value}}
dt(v-if='item.typesetter.value!=""') Sadzba a typografia
dd(v-if='item.typesetter.value!=""')
span {{item.typesetter.value}}
dt(v-if='item.art_director.value!=""') Umelecké smerovanie
dd(v-if='item.art_director.value!=""')
span {{item.art_director.value}}
dt Jazyk
dd
meta(itemprop='inLanguage', content='rue')
| {{item.language.value}}
dt ISBN
dd(itemprop='isbn') {{item.isbn.value}}
dt Rok vydania
dd
meta(itemprop='copyrightYear', :content='item.date_published.value.getFullYear()')
meta(itemprop='datePublished', :content='formatDate(item.date_published.value)')
| {{item.date_published.value.getFullYear()}}
dt Vydavateľ
dd(itemprop='publisher', itemtype='https://schema.org/Organization', itemscope='')
span(itemprop='name') {{item.publisher.value}}
dt Vydanie
dd(itemprop='bookEdition') {{item.book_edition.value}}
dt Väzba
dd
link(itemprop='bookFormat', href='https://schema.org/Hardcover')
| {{item.book_format.value}}
dt Rozmer
dd {{item.dimensions.value}}
dt Hmotnosť
dd {{item.weight.value}}
dt Počet strán
dd(itemprop='numberOfPages') {{item.number_of_pages.value}}
dt Písmo
dd {{item.typeface.value}}
dt Papier
dd(itemprop='material') {{item.paper.value}}
dt Tlač
dd {{item.printer.value}}
dt Finančná podpora
dd(itemprop='sponsor', itemtype='https://schema.org/Organization', itemscope='')
span(itemprop='name') {{item.financial_aid.value}}
</template>
<script>
const moment = require('moment');
export default {
props: ['item'],
methods: {
formatDate(value) {
const dateLocale = 'sk';
const dateFormat = 'YYYY-MM-DD'; // 2019-01-20
return moment(value).locale(dateLocale).format(dateFormat)
}
}
}
</script>