@museumwnf/viewer-layout 3.76.1 → 3.78.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +5 -53
- package/dist/{LegacyItemSheet-B4Ob4upz.js → LegacyItemSheet-CNooycyz.js} +112 -97
- package/dist/{Theme-DvCv48p7.js → Theme-BCn6_VkI.js} +13 -13
- package/dist/data-D9H1tB75.js +98 -0
- package/dist/dxa.js +602 -596
- package/dist/{themeSpecs-CKgLOhlP.js → themeSpecs-BJ82RvA1.js} +1 -1
- package/dist/viewer-layout.css +1 -1
- package/package.json +2 -3
- package/src/dxa/relatedKind.js +11 -0
- package/src/dxa/testing.js +26 -13
- package/dist/data-BI5v-QYD.js +0 -81
- package/dist/publications.js +0 -1017
- package/dist/travels.js +0 -742
package/dist/publications.js
DELETED
|
@@ -1,1017 +0,0 @@
|
|
|
1
|
-
import { r as e } from "./chrome-Bv_mLlHM.js";
|
|
2
|
-
import { Fragment as t, computed as n, createBlock as r, createCommentVNode as i, createElementBlock as a, createElementVNode as o, createTextVNode as s, createVNode as c, normalizeClass as l, onBeforeUnmount as u, onMounted as d, openBlock as f, reactive as p, ref as m, renderList as h, renderSlot as g, resolveComponent as _, toDisplayString as v, unref as y, vModelSelect as b, vModelText as x, vShow as S, watch as C, withCtx as w, withDirectives as T, withKeys as ee, withModifiers as E } from "vue";
|
|
3
|
-
import { byId as D, entityRef as O, isRtl as te, languageLabels as k, mwnfLinks as A, offeredLanguages as j, paginate as M, renderBlock as N, sectionMeta as P, useDataPackage as F, useI18n as I, useSiteConfig as L } from "@museumwnf/viewer-core";
|
|
4
|
-
import { useRoute as R, useRouter as z } from "vue-router";
|
|
5
|
-
// src/publications/rules.js
|
|
6
|
-
var B = [
|
|
7
|
-
"publications",
|
|
8
|
-
"editions",
|
|
9
|
-
"tags",
|
|
10
|
-
"countries",
|
|
11
|
-
"languages"
|
|
12
|
-
], ne = 12, V = Object.freeze([
|
|
13
|
-
{
|
|
14
|
-
slug: "new",
|
|
15
|
-
label: "publications.category.new",
|
|
16
|
-
menu: "publications.menu.new",
|
|
17
|
-
match: null
|
|
18
|
-
},
|
|
19
|
-
{
|
|
20
|
-
slug: "virtual-museum-books",
|
|
21
|
-
category: "virtual-museum",
|
|
22
|
-
label: "publications.category.virtualMuseum"
|
|
23
|
-
},
|
|
24
|
-
{
|
|
25
|
-
slug: "travel-books",
|
|
26
|
-
category: "exhibition-trail",
|
|
27
|
-
label: "publications.category.travelBooks"
|
|
28
|
-
},
|
|
29
|
-
{
|
|
30
|
-
slug: "educational-books",
|
|
31
|
-
category: "educational",
|
|
32
|
-
label: "publications.category.educational"
|
|
33
|
-
},
|
|
34
|
-
{
|
|
35
|
-
slug: "other-books",
|
|
36
|
-
category: "other",
|
|
37
|
-
label: "publications.category.other"
|
|
38
|
-
}
|
|
39
|
-
]);
|
|
40
|
-
function H(e) {
|
|
41
|
-
return e <= 474 ? 1 : e <= 699 ? 2 : e <= 899 ? 3 : e <= 1124 ? 4 : e <= 1349 ? 5 : 6;
|
|
42
|
-
}
|
|
43
|
-
var U = [
|
|
44
|
-
"title",
|
|
45
|
-
"author",
|
|
46
|
-
"isbn",
|
|
47
|
-
"language",
|
|
48
|
-
"country",
|
|
49
|
-
"subject",
|
|
50
|
-
"type",
|
|
51
|
-
"publisher"
|
|
52
|
-
], W = Object.freeze([
|
|
53
|
-
{
|
|
54
|
-
value: "print",
|
|
55
|
-
label: "publications.format.print"
|
|
56
|
-
},
|
|
57
|
-
{
|
|
58
|
-
value: "print-on-demand",
|
|
59
|
-
label: "publications.format.printOnDemand"
|
|
60
|
-
},
|
|
61
|
-
{
|
|
62
|
-
value: "ebook",
|
|
63
|
-
label: "publications.format.ebook"
|
|
64
|
-
}
|
|
65
|
-
]);
|
|
66
|
-
function re(e, t) {
|
|
67
|
-
return !e || !t ? !1 : typeof t.match == "function" ? !!t.match(e) : t.match !== null && e.category === t.category;
|
|
68
|
-
}
|
|
69
|
-
function ie(e, t = V) {
|
|
70
|
-
return t.find((t) => t.slug === e) ?? null;
|
|
71
|
-
}
|
|
72
|
-
function ae(e, t = 6) {
|
|
73
|
-
let n = Array.isArray(e) ? e : [];
|
|
74
|
-
return n.length > t ? {
|
|
75
|
-
shown: n.slice(0, t),
|
|
76
|
-
more: !0
|
|
77
|
-
} : {
|
|
78
|
-
shown: n,
|
|
79
|
-
more: !1
|
|
80
|
-
};
|
|
81
|
-
}
|
|
82
|
-
function oe(e, t) {
|
|
83
|
-
return t ? t.length <= e ? t : `${t.substring(0, t.lastIndexOf(" ", e))}...` : t ?? "";
|
|
84
|
-
}
|
|
85
|
-
var se = (e, t) => (e.display_order ?? Infinity) - (t.display_order ?? Infinity);
|
|
86
|
-
function G(e, t, n = null) {
|
|
87
|
-
let r = [];
|
|
88
|
-
for (let i of e?.edition_ids ?? []) {
|
|
89
|
-
let e = t.get(i);
|
|
90
|
-
e && (!n || e.language === n) && r.push(e);
|
|
91
|
-
}
|
|
92
|
-
return r.sort(se);
|
|
93
|
-
}
|
|
94
|
-
function ce(e, t, n = null) {
|
|
95
|
-
let r = (e) => Number(e.publish_year) || 0;
|
|
96
|
-
return G(e, t, n).sort((e, t) => r(t) - r(e) || se(e, t));
|
|
97
|
-
}
|
|
98
|
-
function K(e, t) {
|
|
99
|
-
let n = new Set(G(e, t).map((e) => e.language).filter(Boolean));
|
|
100
|
-
return (n.size ? [...n] : [...e?.languages ?? []]).sort();
|
|
101
|
-
}
|
|
102
|
-
function q(e, t, n = null) {
|
|
103
|
-
let r = K(e, t);
|
|
104
|
-
return n && r.includes(n) ? n : e?.language && r.includes(e.language) ? e.language : r[0] ?? e?.language ?? "en";
|
|
105
|
-
}
|
|
106
|
-
function le(e) {
|
|
107
|
-
let t = [];
|
|
108
|
-
for (let n of e ?? []) {
|
|
109
|
-
let e = String(n?.binding ?? "").trim();
|
|
110
|
-
e && !t.includes(e) && t.push(e);
|
|
111
|
-
}
|
|
112
|
-
return t;
|
|
113
|
-
}
|
|
114
|
-
function ue(e = {}, t = null) {
|
|
115
|
-
let n = t?.texts ?? {}, r = (e, t) => e ?? t ?? null;
|
|
116
|
-
return {
|
|
117
|
-
title: r(n.title, e.title),
|
|
118
|
-
subtitle: r(n.subtitle, e.subtitle),
|
|
119
|
-
about: r(n.description2, e.description),
|
|
120
|
-
moreAbout: r(n.description1, e.introduction),
|
|
121
|
-
note: r(n.remarks1, null),
|
|
122
|
-
authors: r(n.author, e.author_credit),
|
|
123
|
-
photographers: r(n.photographer, e.photography_credit),
|
|
124
|
-
editors: r(n.local_coordinator, e.coordination_credit),
|
|
125
|
-
pages: r(n.count_pages, t?.page_count),
|
|
126
|
-
images: r(n.count_images, t?.image_count),
|
|
127
|
-
plans: r(n.count_plans, t?.plan_count)
|
|
128
|
-
};
|
|
129
|
-
}
|
|
130
|
-
function J(e) {
|
|
131
|
-
let t = e?.documents ?? [];
|
|
132
|
-
return {
|
|
133
|
-
sample: t.find((e) => e?.kind === "sample")?.url ?? null,
|
|
134
|
-
credits: t.find((e) => e?.kind === "credits")?.url ?? null
|
|
135
|
-
};
|
|
136
|
-
}
|
|
137
|
-
function Y(e) {
|
|
138
|
-
return e != null && String(e).trim() !== "";
|
|
139
|
-
}
|
|
140
|
-
function de(e) {
|
|
141
|
-
let t = String(e?.internal_name ?? "").toLowerCase().split(/[^a-z0-9]+/).filter(Boolean);
|
|
142
|
-
return t.length === 0 ? "" : `publications.theme.${t.map((e, t) => t === 0 ? e : e[0].toUpperCase() + e.slice(1)).join("")}`;
|
|
143
|
-
}
|
|
144
|
-
var X = (e) => String(e ?? "").toLocaleLowerCase().normalize("NFD").replace(/[̀-ͯ]/g, ""), fe = (e) => String(e ?? "").replace(/[^0-9xX]/g, "").toLowerCase();
|
|
145
|
-
function pe(e) {
|
|
146
|
-
return U.some((t) => Y(e?.[t]));
|
|
147
|
-
}
|
|
148
|
-
function me(e, t, { editionById: n, textsOf: r }) {
|
|
149
|
-
if (!pe(t)) return [];
|
|
150
|
-
let i = X(t.title).trim(), a = X(t.author).trim(), o = fe(t.isbn);
|
|
151
|
-
return (e ?? []).filter((e) => {
|
|
152
|
-
let s = G(e, n), c = r(e), l = s.map((e) => e.texts ?? {});
|
|
153
|
-
return !(i && ![...c, ...l].some((e) => X(e.title).includes(i) || X(e.subtitle).includes(i)) || a && ![...c.map((e) => e.author_credit), ...l.map((e) => e.author)].some((e) => X(e).includes(a)) || o && !s.some((e) => fe(e.isbn).includes(o)) || Y(t.language) && !s.some((e) => e.language === t.language) || Y(t.type) && !s.some((e) => e.format === t.type) || Y(t.publisher) && !s.some((e) => e.publisher === t.publisher) || Y(t.country) && e.country_id !== t.country || Y(t.subject) && !(e.tag_ids ?? []).includes(t.subject));
|
|
154
|
-
});
|
|
155
|
-
}
|
|
156
|
-
// src/publications/data.js
|
|
157
|
-
var he = O("publications"), ge = O("editions"), _e = O("tags"), ve = O("countries"), ye = O("languages");
|
|
158
|
-
function be(e) {
|
|
159
|
-
return e?.publications?.categories ?? V;
|
|
160
|
-
}
|
|
161
|
-
function Z({ languagesToLoad: e = () => [], tiles: t = !1 } = {}) {
|
|
162
|
-
let r = F(), i = L(), { locale: a } = I(), o = D("editions"), s = D("publications"), c = n(() => he.value ?? []), l = () => t ? c.value.map((e) => q(e, o.value)) : [];
|
|
163
|
-
C(() => [.../* @__PURE__ */ new Set([
|
|
164
|
-
"en",
|
|
165
|
-
a.value,
|
|
166
|
-
...e(),
|
|
167
|
-
...l()
|
|
168
|
-
])].filter(Boolean), (e) => Promise.all(e.flatMap((e) => [r.loadTranslations("publications", e), r.loadTranslations("countries", e)])), { immediate: !0 });
|
|
169
|
-
let u = n(() => be(i)), d = (e, t) => r.translations("publications", t)[e?.id] ?? {};
|
|
170
|
-
function f(e) {
|
|
171
|
-
return e ? r.translations("countries", a.value)[e]?.name ?? r.translations("countries", "en")[e]?.name ?? "" : "";
|
|
172
|
-
}
|
|
173
|
-
function p(e) {
|
|
174
|
-
let t = r.manifest.projects?.[e]?.name;
|
|
175
|
-
return t?.[a.value] ?? t?.en ?? "";
|
|
176
|
-
}
|
|
177
|
-
function m(e, t = e) {
|
|
178
|
-
let n = (ye.value ?? []).find((t) => t.code === e);
|
|
179
|
-
return n?.names?.[t] ?? n?.names?.[e] ?? String(e ?? "").toUpperCase();
|
|
180
|
-
}
|
|
181
|
-
function h(e, t = null) {
|
|
182
|
-
let n = o.value, r = q(e, n, t), i = G(e, n, r), a = d(e, r), s = i[0]?.texts ?? {}, c = i.length ? i[0].cover : e.cover;
|
|
183
|
-
return {
|
|
184
|
-
id: e.id,
|
|
185
|
-
language: r,
|
|
186
|
-
to: {
|
|
187
|
-
name: "publication",
|
|
188
|
-
params: {
|
|
189
|
-
id: e.id,
|
|
190
|
-
language: r
|
|
191
|
-
}
|
|
192
|
-
},
|
|
193
|
-
cover: c?.url ?? null,
|
|
194
|
-
languages: ae(K(e, n)),
|
|
195
|
-
country: f(e.country_id),
|
|
196
|
-
project: p(e.project_id),
|
|
197
|
-
title: s.title || a.title || "",
|
|
198
|
-
subtitle: s.subtitle || a.subtitle || "",
|
|
199
|
-
author: s.author || a.author_credit || "",
|
|
200
|
-
formats: le(i).join(", ")
|
|
201
|
-
};
|
|
202
|
-
}
|
|
203
|
-
function g(e, t) {
|
|
204
|
-
let n = (e) => r.translations("countries", "en")[e.country_id]?.name ?? "";
|
|
205
|
-
return c.value.filter((n) => t(n, e)).map((e, t) => ({
|
|
206
|
-
publication: e,
|
|
207
|
-
order: t,
|
|
208
|
-
key: n(e)
|
|
209
|
-
})).sort((e, t) => e.key.localeCompare(t.key) || e.order - t.order).map((e) => e.publication);
|
|
210
|
-
}
|
|
211
|
-
return {
|
|
212
|
-
pkg: r,
|
|
213
|
-
config: i,
|
|
214
|
-
publications: c,
|
|
215
|
-
editions: ge,
|
|
216
|
-
tags: _e,
|
|
217
|
-
countries: ve,
|
|
218
|
-
languages: ye,
|
|
219
|
-
editionById: o,
|
|
220
|
-
publicationById: s,
|
|
221
|
-
categories: u,
|
|
222
|
-
text: d,
|
|
223
|
-
tile: h,
|
|
224
|
-
inCategory: g,
|
|
225
|
-
countryName: f,
|
|
226
|
-
projectName: p,
|
|
227
|
-
languageName: m
|
|
228
|
-
};
|
|
229
|
-
}
|
|
230
|
-
// src/publications/footer.js
|
|
231
|
-
var Q = A.portal, xe = Object.freeze({
|
|
232
|
-
columns: [
|
|
233
|
-
{
|
|
234
|
-
heading: "publications.footer.more",
|
|
235
|
-
links: [
|
|
236
|
-
{
|
|
237
|
-
label: "publications.footer.chronology",
|
|
238
|
-
href: `${Q}/about/chronology`
|
|
239
|
-
},
|
|
240
|
-
{
|
|
241
|
-
label: "publications.footer.support",
|
|
242
|
-
href: `${Q}/about/support`
|
|
243
|
-
},
|
|
244
|
-
{
|
|
245
|
-
label: "publications.footer.volunteers",
|
|
246
|
-
href: `${Q}/about/volunteers`
|
|
247
|
-
},
|
|
248
|
-
{
|
|
249
|
-
label: "publications.footer.honoraryCommittee",
|
|
250
|
-
href: `${Q}/about/honorary-committee`
|
|
251
|
-
},
|
|
252
|
-
{
|
|
253
|
-
label: "publications.footer.commemoration",
|
|
254
|
-
href: `${Q}/about/commemoration`
|
|
255
|
-
}
|
|
256
|
-
]
|
|
257
|
-
},
|
|
258
|
-
{
|
|
259
|
-
heading: "publications.footer.archive",
|
|
260
|
-
links: [{
|
|
261
|
-
label: "publications.footer.leagueOfArabStates",
|
|
262
|
-
href: `${Q}/league-of-arab-states/`
|
|
263
|
-
}, {
|
|
264
|
-
label: "publications.footer.cafeteria",
|
|
265
|
-
href: `${Q}/cafeteria/`
|
|
266
|
-
}]
|
|
267
|
-
},
|
|
268
|
-
{
|
|
269
|
-
heading: "publications.footer.others",
|
|
270
|
-
links: [{
|
|
271
|
-
label: "publications.footer.pressLounge",
|
|
272
|
-
href: `${Q}/about/press-lounge`
|
|
273
|
-
}, {
|
|
274
|
-
label: "publications.footer.languagePolicy",
|
|
275
|
-
href: `${Q}/about/language-policy`
|
|
276
|
-
}]
|
|
277
|
-
},
|
|
278
|
-
{
|
|
279
|
-
heading: "publications.footer.contact",
|
|
280
|
-
links: [{
|
|
281
|
-
label: "publications.footer.contactTeam",
|
|
282
|
-
href: A.contact
|
|
283
|
-
}, {
|
|
284
|
-
label: "publications.footer.contactPartners",
|
|
285
|
-
href: `${Q}/partner_list.php`
|
|
286
|
-
}]
|
|
287
|
-
}
|
|
288
|
-
],
|
|
289
|
-
bottom: [
|
|
290
|
-
{
|
|
291
|
-
label: "publications.footer.contactLink",
|
|
292
|
-
href: A.contact
|
|
293
|
-
},
|
|
294
|
-
{
|
|
295
|
-
label: "publications.footer.legalNotice",
|
|
296
|
-
href: A.legalNotice
|
|
297
|
-
},
|
|
298
|
-
{
|
|
299
|
-
label: "publications.footer.credits",
|
|
300
|
-
href: A.credits
|
|
301
|
-
},
|
|
302
|
-
{
|
|
303
|
-
label: "publications.footer.cookies",
|
|
304
|
-
href: A.cookies
|
|
305
|
-
}
|
|
306
|
-
]
|
|
307
|
-
}), Se = { class: "mwnf-books" }, Ce = { class: "mwnf-books-header" }, we = { class: "mwnf-books-header__main" }, Te = { class: "mwnf-books-header__logo" }, Ee = ["href"], De = ["src"], Oe = { class: "mwnf-books-header__links" }, ke = { class: "mwnf-books-header__nav" }, Ae = ["href"], je = ["href"], Me = ["aria-expanded", "aria-label"], Ne = ["aria-label"], Pe = { class: "mwnf-books-search" }, Fe = ["aria-expanded", "aria-label"], Ie = {
|
|
308
|
-
key: 0,
|
|
309
|
-
"aria-hidden": "true"
|
|
310
|
-
}, Le = {
|
|
311
|
-
key: 1,
|
|
312
|
-
"aria-hidden": "true"
|
|
313
|
-
}, Re = {
|
|
314
|
-
key: 0,
|
|
315
|
-
class: "mwnf-books-search__panel"
|
|
316
|
-
}, ze = { class: "mwnf-books-search__explanation" }, Be = ["placeholder", "aria-label"], Ve = ["placeholder", "aria-label"], He = ["placeholder", "aria-label"], Ue = ["onUpdate:modelValue", "aria-label"], We = { value: "" }, Ge = ["value"], Ke = { class: "mwnf-books-search__buttons" }, qe = {
|
|
317
|
-
type: "submit",
|
|
318
|
-
class: "mwnf-books-search__button"
|
|
319
|
-
}, Je = { class: "mwnf-books-main" }, Ye = { class: "mwnf-books-footer" }, Xe = { class: "mwnf-books-footer__top" }, Ze = { class: "mwnf-books-footer__column mwnf-books-footer__brand" }, Qe = ["src"], $e = { class: "mwnf-books-footer__heading" }, et = ["href"], tt = { class: "mwnf-books-footer__bottom" }, nt = ["href"], rt = {
|
|
320
|
-
__name: "Shell",
|
|
321
|
-
props: {
|
|
322
|
-
languages: {
|
|
323
|
-
type: Array,
|
|
324
|
-
default: () => []
|
|
325
|
-
},
|
|
326
|
-
language: {
|
|
327
|
-
type: String,
|
|
328
|
-
default: "en"
|
|
329
|
-
}
|
|
330
|
-
},
|
|
331
|
-
setup(r) {
|
|
332
|
-
let { t: u } = I(), d = L(), S = R(), ee = z(), D = Z(), O = (t) => e(d.chrome, t), te = n(() => be(d)), k = n(() => d.publications?.footer ?? xe), j = n(() => d.publications?.portal ?? A.portal), M = m(!1), N = m(!0), P = p(Object.fromEntries(U.map((e) => [e, ""])));
|
|
333
|
-
C(() => S.query, (e) => {
|
|
334
|
-
if (S.name === "results") for (let t of U) P[t] = typeof e[t] == "string" ? e[t] : "";
|
|
335
|
-
}, { immediate: !0 });
|
|
336
|
-
let F = (e) => e.sort((e, t) => e.label.localeCompare(t.label)), B = n(() => D.editions.value ?? []), ne = n(() => ({
|
|
337
|
-
language: F([...new Set(B.value.map((e) => e.language).filter(Boolean))].map((e) => ({
|
|
338
|
-
value: e,
|
|
339
|
-
label: D.languageName(e, "en")
|
|
340
|
-
}))),
|
|
341
|
-
country: F([...new Set(D.publications.value.map((e) => e.country_id).filter(Boolean))].map((e) => ({
|
|
342
|
-
value: e,
|
|
343
|
-
label: D.countryName(e)
|
|
344
|
-
}))),
|
|
345
|
-
subject: F((D.tags.value ?? []).filter((e) => e.category === "subject").map((e) => ({
|
|
346
|
-
value: e.id,
|
|
347
|
-
label: e.description ?? e.internal_name
|
|
348
|
-
}))),
|
|
349
|
-
type: F(W.map((e) => ({
|
|
350
|
-
value: e.value,
|
|
351
|
-
label: u(e.label)
|
|
352
|
-
}))),
|
|
353
|
-
publisher: F([...new Set(B.value.map((e) => e.publisher).filter(Boolean))].map((e) => ({
|
|
354
|
-
value: e,
|
|
355
|
-
label: e
|
|
356
|
-
})))
|
|
357
|
-
})), V = [
|
|
358
|
-
"language",
|
|
359
|
-
"country",
|
|
360
|
-
"subject",
|
|
361
|
-
"type",
|
|
362
|
-
"publisher"
|
|
363
|
-
];
|
|
364
|
-
function H() {
|
|
365
|
-
for (let e of U) P[e] = "";
|
|
366
|
-
}
|
|
367
|
-
function re() {
|
|
368
|
-
let e = Object.fromEntries(U.filter((e) => String(P[e]).trim() !== "").map((e) => [e, String(P[e]).trim()]));
|
|
369
|
-
ee.push({
|
|
370
|
-
name: "results",
|
|
371
|
-
query: e
|
|
372
|
-
});
|
|
373
|
-
}
|
|
374
|
-
return (e, n) => {
|
|
375
|
-
let r = _("RouterLink");
|
|
376
|
-
return f(), a("div", Se, [
|
|
377
|
-
o("header", Ce, [
|
|
378
|
-
o("div", we, [o("div", Te, [o("a", { href: j.value }, [O("legacy/logo-blue.png") ? (f(), a("img", {
|
|
379
|
-
key: 0,
|
|
380
|
-
src: O("legacy/logo-blue.png"),
|
|
381
|
-
alt: ""
|
|
382
|
-
}, null, 8, De)) : i("", !0)], 8, Ee)]), o("div", Oe, [c(r, {
|
|
383
|
-
class: "mwnf-books-header__slogan",
|
|
384
|
-
to: { name: "home" }
|
|
385
|
-
}, {
|
|
386
|
-
default: w(() => [s(v(y(u)("publications.header.title")), 1)]),
|
|
387
|
-
_: 1
|
|
388
|
-
}), o("nav", ke, [
|
|
389
|
-
o("a", {
|
|
390
|
-
class: "mwnf-books-header__item",
|
|
391
|
-
href: y(A).about,
|
|
392
|
-
target: "_blank"
|
|
393
|
-
}, v(y(u)("publications.header.about")), 9, Ae),
|
|
394
|
-
o("a", {
|
|
395
|
-
class: "mwnf-books-header__item",
|
|
396
|
-
href: y(A).contact,
|
|
397
|
-
target: "_blank"
|
|
398
|
-
}, v(y(u)("publications.header.contact")), 9, je),
|
|
399
|
-
c(r, {
|
|
400
|
-
class: "mwnf-books-header__item",
|
|
401
|
-
to: { name: "home" }
|
|
402
|
-
}, {
|
|
403
|
-
default: w(() => [s(v(y(u)("publications.header.home")), 1)]),
|
|
404
|
-
_: 1
|
|
405
|
-
}),
|
|
406
|
-
o("button", {
|
|
407
|
-
type: "button",
|
|
408
|
-
class: "mwnf-books-header__burger",
|
|
409
|
-
"aria-expanded": M.value,
|
|
410
|
-
"aria-label": y(u)("layout.nav.menu"),
|
|
411
|
-
onClick: n[0] ||= (e) => M.value = !M.value
|
|
412
|
-
}, "☰", 8, Me)
|
|
413
|
-
])])]),
|
|
414
|
-
o("nav", {
|
|
415
|
-
class: l(["mwnf-books-menu", { "mwnf-books-menu--open": M.value }]),
|
|
416
|
-
"aria-label": y(u)("layout.nav.label")
|
|
417
|
-
}, [(f(!0), a(t, null, h(te.value, (e) => (f(), a("div", {
|
|
418
|
-
key: e.slug,
|
|
419
|
-
class: "mwnf-books-menu__item"
|
|
420
|
-
}, [c(r, {
|
|
421
|
-
to: {
|
|
422
|
-
name: "category",
|
|
423
|
-
params: { category: e.slug }
|
|
424
|
-
},
|
|
425
|
-
onClick: n[1] ||= (e) => M.value = !1
|
|
426
|
-
}, {
|
|
427
|
-
default: w(() => [s(v(y(u)(e.menu ?? e.label)), 1)]),
|
|
428
|
-
_: 2
|
|
429
|
-
}, 1032, ["to"])]))), 128))], 10, Ne),
|
|
430
|
-
o("div", Pe, [o("button", {
|
|
431
|
-
type: "button",
|
|
432
|
-
class: "mwnf-books-search__toggle",
|
|
433
|
-
"aria-expanded": N.value,
|
|
434
|
-
"aria-label": y(u)("core.action.search"),
|
|
435
|
-
onClick: n[2] ||= (e) => N.value = !N.value
|
|
436
|
-
}, [N.value ? (f(), a("span", Ie, "⌃⌃")) : (f(), a("span", Le, "⌄ ⚲ ⌄"))], 8, Fe), N.value ? (f(), a("div", Re, [o("p", ze, v(y(u)("publications.search.explanation")), 1), o("form", {
|
|
437
|
-
class: "mwnf-books-search__form",
|
|
438
|
-
onSubmit: E(re, ["prevent"])
|
|
439
|
-
}, [
|
|
440
|
-
T(o("input", {
|
|
441
|
-
"onUpdate:modelValue": n[3] ||= (e) => P.title = e,
|
|
442
|
-
class: "mwnf-books-search__input",
|
|
443
|
-
type: "search",
|
|
444
|
-
placeholder: y(u)("publications.search.title"),
|
|
445
|
-
"aria-label": y(u)("publications.search.title")
|
|
446
|
-
}, null, 8, Be), [[x, P.title]]),
|
|
447
|
-
T(o("input", {
|
|
448
|
-
"onUpdate:modelValue": n[4] ||= (e) => P.author = e,
|
|
449
|
-
class: "mwnf-books-search__input",
|
|
450
|
-
type: "search",
|
|
451
|
-
placeholder: y(u)("publications.search.author"),
|
|
452
|
-
"aria-label": y(u)("publications.search.author")
|
|
453
|
-
}, null, 8, Ve), [[x, P.author]]),
|
|
454
|
-
T(o("input", {
|
|
455
|
-
"onUpdate:modelValue": n[5] ||= (e) => P.isbn = e,
|
|
456
|
-
class: "mwnf-books-search__input",
|
|
457
|
-
type: "search",
|
|
458
|
-
placeholder: y(u)("publications.search.isbn"),
|
|
459
|
-
"aria-label": y(u)("publications.search.isbn")
|
|
460
|
-
}, null, 8, He), [[x, P.isbn]]),
|
|
461
|
-
(f(), a(t, null, h(V, (e) => T(o("select", {
|
|
462
|
-
key: e,
|
|
463
|
-
"onUpdate:modelValue": (t) => P[e] = t,
|
|
464
|
-
class: "mwnf-books-search__input",
|
|
465
|
-
"aria-label": y(u)(`publications.search.${e}`)
|
|
466
|
-
}, [o("option", We, v(y(u)(`publications.search.${e}`)), 1), (f(!0), a(t, null, h(ne.value[e], (e) => (f(), a("option", {
|
|
467
|
-
key: e.value,
|
|
468
|
-
value: e.value
|
|
469
|
-
}, v(e.label), 9, Ge))), 128))], 8, Ue), [[b, P[e]]])), 64)),
|
|
470
|
-
o("div", Ke, [o("button", {
|
|
471
|
-
type: "button",
|
|
472
|
-
class: "mwnf-books-search__button mwnf-books-search__button--reset",
|
|
473
|
-
onClick: H
|
|
474
|
-
}, v(y(u)("publications.search.reset")), 1), o("button", qe, v(y(u)("publications.search.submit")), 1)])
|
|
475
|
-
], 32)])) : i("", !0)])
|
|
476
|
-
]),
|
|
477
|
-
o("main", Je, [g(e.$slots, "default")]),
|
|
478
|
-
o("footer", Ye, [o("div", Xe, [o("div", Ze, [O("legacy/logo-white.png") ? (f(), a("img", {
|
|
479
|
-
key: 0,
|
|
480
|
-
src: O("legacy/logo-white.png"),
|
|
481
|
-
alt: ""
|
|
482
|
-
}, null, 8, Qe)) : i("", !0), o("p", null, v(y(u)("publications.footer.slogan")), 1)]), (f(!0), a(t, null, h(k.value.columns, (e) => (f(), a("div", {
|
|
483
|
-
key: e.heading,
|
|
484
|
-
class: "mwnf-books-footer__column"
|
|
485
|
-
}, [o("p", $e, v(y(u)(e.heading)), 1), (f(!0), a(t, null, h(e.links, (e) => (f(), a("a", {
|
|
486
|
-
key: e.label,
|
|
487
|
-
class: "mwnf-books-footer__link",
|
|
488
|
-
href: e.href
|
|
489
|
-
}, v(y(u)(e.label)), 9, et))), 128))]))), 128))]), o("div", tt, [(f(!0), a(t, null, h(k.value.bottom, (e) => (f(), a("a", {
|
|
490
|
-
key: e.label,
|
|
491
|
-
class: "mwnf-books-footer__bottom-link",
|
|
492
|
-
href: e.href
|
|
493
|
-
}, v(y(u)(e.label)), 9, nt))), 128))])])
|
|
494
|
-
]);
|
|
495
|
-
};
|
|
496
|
-
}
|
|
497
|
-
}, it = {
|
|
498
|
-
class: "mwnf-books-tile__tooltip",
|
|
499
|
-
role: "tooltip"
|
|
500
|
-
}, at = { class: "mwnf-books-tile__media" }, ot = {
|
|
501
|
-
key: 0,
|
|
502
|
-
class: "mwnf-books-tile__cover"
|
|
503
|
-
}, st = ["src"], ct = {
|
|
504
|
-
key: 1,
|
|
505
|
-
class: "mwnf-books-tile__cover mwnf-books-tile__cover--none"
|
|
506
|
-
}, lt = { class: "mwnf-books-tile__languages" }, ut = {
|
|
507
|
-
key: 0,
|
|
508
|
-
class: "mwnf-books-tile__language"
|
|
509
|
-
}, dt = { class: "mwnf-books-tile__info" }, ft = {
|
|
510
|
-
key: 0,
|
|
511
|
-
class: "mwnf-books-tile__country"
|
|
512
|
-
}, pt = {
|
|
513
|
-
key: 1,
|
|
514
|
-
class: "mwnf-books-tile__project"
|
|
515
|
-
}, mt = { class: "mwnf-books-tile__title" }, ht = {
|
|
516
|
-
key: 2,
|
|
517
|
-
class: "mwnf-books-tile__subtitle"
|
|
518
|
-
}, gt = {
|
|
519
|
-
key: 3,
|
|
520
|
-
class: "mwnf-books-tile__author"
|
|
521
|
-
}, _t = {
|
|
522
|
-
key: 4,
|
|
523
|
-
class: "mwnf-books-tile__formats"
|
|
524
|
-
}, vt = {
|
|
525
|
-
__name: "Tile",
|
|
526
|
-
props: {
|
|
527
|
-
tile: {
|
|
528
|
-
type: Object,
|
|
529
|
-
required: !0
|
|
530
|
-
},
|
|
531
|
-
variant: {
|
|
532
|
-
type: String,
|
|
533
|
-
default: "home"
|
|
534
|
-
}
|
|
535
|
-
},
|
|
536
|
-
setup(e) {
|
|
537
|
-
let r = e, { t: s } = I(), u = n(() => r.variant === "home" ? oe(55, r.tile.subtitle) : r.tile.subtitle);
|
|
538
|
-
return (n, r) => {
|
|
539
|
-
let d = _("RouterLink");
|
|
540
|
-
return f(), a("div", { class: l(["mwnf-books-tile", `mwnf-books-tile--${e.variant}`]) }, [c(d, {
|
|
541
|
-
class: "mwnf-books-tile__link",
|
|
542
|
-
to: e.tile.to
|
|
543
|
-
}, {
|
|
544
|
-
default: w(() => [
|
|
545
|
-
o("span", it, v(y(s)("publications.card.hover")), 1),
|
|
546
|
-
o("span", at, [e.tile.cover ? (f(), a("span", ot, [o("img", {
|
|
547
|
-
src: e.tile.cover,
|
|
548
|
-
alt: "",
|
|
549
|
-
loading: "lazy"
|
|
550
|
-
}, null, 8, st)])) : (f(), a("span", ct, v(y(s)("publications.card.imageComingSoon")), 1)), o("span", lt, [(f(!0), a(t, null, h(e.tile.languages.shown, (e) => (f(), a("span", {
|
|
551
|
-
key: e,
|
|
552
|
-
class: "mwnf-books-tile__language"
|
|
553
|
-
}, v(e.toUpperCase()), 1))), 128)), e.tile.languages.more ? (f(), a("span", ut, "+")) : i("", !0)])]),
|
|
554
|
-
o("span", dt, [
|
|
555
|
-
e.tile.country ? (f(), a("span", ft, v(e.tile.country), 1)) : i("", !0),
|
|
556
|
-
e.tile.project ? (f(), a("span", pt, v(e.tile.project), 1)) : i("", !0),
|
|
557
|
-
o("span", mt, v(e.tile.title), 1),
|
|
558
|
-
u.value ? (f(), a("span", ht, v(u.value), 1)) : i("", !0),
|
|
559
|
-
e.variant === "category" && e.tile.author ? (f(), a("span", gt, v(y(s)("publications.edition.authors")) + ": " + v(e.tile.author), 1)) : i("", !0),
|
|
560
|
-
e.tile.formats ? (f(), a("span", _t, v(e.tile.formats), 1)) : i("", !0)
|
|
561
|
-
])
|
|
562
|
-
]),
|
|
563
|
-
_: 1
|
|
564
|
-
}, 8, ["to"])], 2);
|
|
565
|
-
};
|
|
566
|
-
}
|
|
567
|
-
}, yt = { class: "mwnf-books-home" }, bt = { class: "mwnf-books-home__label" }, xt = { class: "mwnf-books-home__tiles" }, St = {
|
|
568
|
-
__name: "Home",
|
|
569
|
-
setup(e) {
|
|
570
|
-
let { t: i } = I(), l = Z({ tiles: !0 }), p = m(typeof window < "u" ? window.innerWidth : 1400), g = () => {
|
|
571
|
-
p.value = window.innerWidth;
|
|
572
|
-
};
|
|
573
|
-
d(() => window.addEventListener("resize", g)), u(() => window.removeEventListener("resize", g));
|
|
574
|
-
let b = n(() => l.categories.value.map((e) => ({
|
|
575
|
-
entry: e,
|
|
576
|
-
tiles: l.inCategory(e, re).slice(0, Math.min(12, H(p.value))).map((e) => l.tile(e))
|
|
577
|
-
})).filter((e) => e.tiles.length));
|
|
578
|
-
return (e, n) => {
|
|
579
|
-
let l = _("RouterLink");
|
|
580
|
-
return f(), a("div", yt, [(f(!0), a(t, null, h(b.value, (e) => (f(), a("section", {
|
|
581
|
-
key: e.entry.slug,
|
|
582
|
-
class: "mwnf-books-home__band"
|
|
583
|
-
}, [
|
|
584
|
-
o("h2", bt, [s(v(y(i)(e.entry.label)) + " ", 1), c(l, {
|
|
585
|
-
class: "mwnf-books-home__see-all",
|
|
586
|
-
to: {
|
|
587
|
-
name: "category",
|
|
588
|
-
params: { category: e.entry.slug }
|
|
589
|
-
}
|
|
590
|
-
}, {
|
|
591
|
-
default: w(() => [s(v(y(i)("publications.home.seeAll")) + " ›", 1)]),
|
|
592
|
-
_: 1
|
|
593
|
-
}, 8, ["to"])]),
|
|
594
|
-
o("div", xt, [(f(!0), a(t, null, h(e.tiles, (e) => (f(), r(vt, {
|
|
595
|
-
key: e.id,
|
|
596
|
-
tile: e,
|
|
597
|
-
variant: "home"
|
|
598
|
-
}, null, 8, ["tile"]))), 128))]),
|
|
599
|
-
c(l, {
|
|
600
|
-
class: "mwnf-books-home__see-all-below",
|
|
601
|
-
to: {
|
|
602
|
-
name: "category",
|
|
603
|
-
params: { category: e.entry.slug }
|
|
604
|
-
}
|
|
605
|
-
}, {
|
|
606
|
-
default: w(() => [s(v(y(i)("publications.home.seeAll")) + " ›", 1)]),
|
|
607
|
-
_: 1
|
|
608
|
-
}, 8, ["to"])
|
|
609
|
-
]))), 128))]);
|
|
610
|
-
};
|
|
611
|
-
}
|
|
612
|
-
}, Ct = {
|
|
613
|
-
key: 0,
|
|
614
|
-
class: "mwnf-books-pages"
|
|
615
|
-
}, wt = ["disabled"], Tt = ["disabled"], Et = { class: "mwnf-books-pages__numbers" }, Dt = [
|
|
616
|
-
"disabled",
|
|
617
|
-
"aria-current",
|
|
618
|
-
"onClick"
|
|
619
|
-
], Ot = ["disabled"], kt = ["disabled"], $ = {
|
|
620
|
-
__name: "Pagination",
|
|
621
|
-
props: { pageInfo: {
|
|
622
|
-
type: Object,
|
|
623
|
-
required: !0
|
|
624
|
-
} },
|
|
625
|
-
emits: ["navigate"],
|
|
626
|
-
setup(e, { emit: r }) {
|
|
627
|
-
let s = e, c = r, { t: l } = I(), u = n(() => s.pageInfo.currentPage), d = n(() => s.pageInfo.lastPage), p = n(() => Array.from({ length: d.value }, (e, t) => t + 1)), m = (e) => e < 1 || e > d.value || e === u.value;
|
|
628
|
-
function g(e) {
|
|
629
|
-
m(e) || c("navigate", e);
|
|
630
|
-
}
|
|
631
|
-
return (e, n) => d.value > 1 ? (f(), a("nav", Ct, [
|
|
632
|
-
o("button", {
|
|
633
|
-
type: "button",
|
|
634
|
-
class: "mwnf-books-pages__button",
|
|
635
|
-
disabled: m(1),
|
|
636
|
-
onClick: n[0] ||= (e) => g(1)
|
|
637
|
-
}, "<< " + v(y(l)("publications.pagination.first")), 9, wt),
|
|
638
|
-
o("button", {
|
|
639
|
-
type: "button",
|
|
640
|
-
class: "mwnf-books-pages__button",
|
|
641
|
-
disabled: m(u.value - 1),
|
|
642
|
-
onClick: n[1] ||= (e) => g(u.value - 1)
|
|
643
|
-
}, "< " + v(y(l)("publications.pagination.previous")), 9, Tt),
|
|
644
|
-
o("span", Et, [(f(!0), a(t, null, h(p.value, (e) => (f(), a("button", {
|
|
645
|
-
key: e,
|
|
646
|
-
type: "button",
|
|
647
|
-
class: "mwnf-books-pages__button",
|
|
648
|
-
disabled: m(e),
|
|
649
|
-
"aria-current": e === u.value ? "page" : void 0,
|
|
650
|
-
onClick: (t) => g(e)
|
|
651
|
-
}, v(e), 9, Dt))), 128))]),
|
|
652
|
-
o("button", {
|
|
653
|
-
type: "button",
|
|
654
|
-
class: "mwnf-books-pages__button",
|
|
655
|
-
disabled: m(u.value + 1),
|
|
656
|
-
onClick: n[2] ||= (e) => g(u.value + 1)
|
|
657
|
-
}, v(y(l)("publications.pagination.next")) + " >", 9, Ot),
|
|
658
|
-
o("button", {
|
|
659
|
-
type: "button",
|
|
660
|
-
class: "mwnf-books-pages__button",
|
|
661
|
-
disabled: m(d.value),
|
|
662
|
-
onClick: n[3] ||= (e) => g(d.value)
|
|
663
|
-
}, v(y(l)("publications.pagination.last")) + " >>", 9, kt)
|
|
664
|
-
])) : i("", !0);
|
|
665
|
-
}
|
|
666
|
-
}, At = { class: "mwnf-books-list mwnf-books-category" }, jt = { class: "mwnf-books-list__title" }, Mt = { class: "mwnf-books-list__tiles" }, Nt = {
|
|
667
|
-
key: 1,
|
|
668
|
-
class: "mwnf-books-list__empty"
|
|
669
|
-
}, Pt = {
|
|
670
|
-
__name: "Category",
|
|
671
|
-
props: { category: {
|
|
672
|
-
type: String,
|
|
673
|
-
required: !0
|
|
674
|
-
} },
|
|
675
|
-
setup(e) {
|
|
676
|
-
let i = e, { t: s } = I(), l = R(), u = z(), d = Z({ tiles: !0 }), p = n(() => ie(i.category, d.categories.value)), m = n(() => M(p.value ? d.inCategory(p.value, re) : [], l.query.page ?? 1, 12)), g = n(() => m.value.rows.map((e) => d.tile(e)));
|
|
677
|
-
function _(e) {
|
|
678
|
-
u.push({ query: {
|
|
679
|
-
...l.query,
|
|
680
|
-
page: String(e)
|
|
681
|
-
} });
|
|
682
|
-
}
|
|
683
|
-
return (e, n) => (f(), a("div", At, [p.value ? (f(), a(t, { key: 0 }, [
|
|
684
|
-
o("h1", jt, v(y(s)(p.value.label)), 1),
|
|
685
|
-
c($, {
|
|
686
|
-
"page-info": m.value,
|
|
687
|
-
onNavigate: _
|
|
688
|
-
}, null, 8, ["page-info"]),
|
|
689
|
-
o("div", Mt, [(f(!0), a(t, null, h(g.value, (e) => (f(), r(vt, {
|
|
690
|
-
key: e.id,
|
|
691
|
-
tile: e,
|
|
692
|
-
variant: "category"
|
|
693
|
-
}, null, 8, ["tile"]))), 128))]),
|
|
694
|
-
c($, {
|
|
695
|
-
"page-info": m.value,
|
|
696
|
-
onNavigate: _
|
|
697
|
-
}, null, 8, ["page-info"])
|
|
698
|
-
], 64)) : (f(), a("p", Nt, v(y(s)("core.notFound.page")), 1))]));
|
|
699
|
-
}
|
|
700
|
-
}, Ft = { class: "mwnf-books-list mwnf-books-results" }, It = { class: "mwnf-books-list__title" }, Lt = { key: 0 }, Rt = {
|
|
701
|
-
key: 0,
|
|
702
|
-
class: "mwnf-books-list__tiles"
|
|
703
|
-
}, zt = {
|
|
704
|
-
key: 1,
|
|
705
|
-
class: "mwnf-books-list__empty"
|
|
706
|
-
}, Bt = {
|
|
707
|
-
key: 2,
|
|
708
|
-
class: "mwnf-books-list__empty"
|
|
709
|
-
}, Vt = {
|
|
710
|
-
__name: "Results",
|
|
711
|
-
setup(e) {
|
|
712
|
-
let { t: s } = I(), l = R(), u = z(), d = n(() => Object.fromEntries(U.map((e) => [e, typeof l.query[e] == "string" ? l.query[e] : ""]))), { availableLanguages: p } = F(), m = Z({ languagesToLoad: () => p("publications") }), g = n(() => pe(d.value)), _ = (e) => (e.languages ?? []).map((t) => m.text(e, t)), b = n(() => me(m.publications.value, d.value, {
|
|
713
|
-
editionById: m.editionById.value,
|
|
714
|
-
textsOf: _
|
|
715
|
-
})), x = n(() => M(b.value, l.query.page ?? 1, 12)), S = n(() => x.value.rows.map((e) => m.tile(e, d.value.language || null))), C = n(() => {
|
|
716
|
-
let e = d.value, t = (m.tags.value ?? []).find((t) => t.id === e.subject), n = W.find((t) => t.value === e.type);
|
|
717
|
-
return [
|
|
718
|
-
e.title,
|
|
719
|
-
e.author,
|
|
720
|
-
e.isbn,
|
|
721
|
-
e.language ? m.languageName(e.language, "en") : "",
|
|
722
|
-
e.country ? m.countryName(e.country) : "",
|
|
723
|
-
t ? t.description ?? t.internal_name : "",
|
|
724
|
-
n ? s(n.label) : "",
|
|
725
|
-
e.publisher
|
|
726
|
-
].filter(Boolean).join(", ");
|
|
727
|
-
});
|
|
728
|
-
function w(e) {
|
|
729
|
-
u.push({ query: {
|
|
730
|
-
...l.query,
|
|
731
|
-
page: String(e)
|
|
732
|
-
} });
|
|
733
|
-
}
|
|
734
|
-
return (e, n) => (f(), a("div", Ft, [
|
|
735
|
-
o("h1", It, [o("span", null, v(y(s)("publications.results.title")), 1), C.value ? (f(), a("span", Lt, v(` ${y(s)("publications.results.for")} "${C.value}"`), 1)) : i("", !0)]),
|
|
736
|
-
c($, {
|
|
737
|
-
"page-info": x.value,
|
|
738
|
-
onNavigate: w
|
|
739
|
-
}, null, 8, ["page-info"]),
|
|
740
|
-
S.value.length ? (f(), a("div", Rt, [(f(!0), a(t, null, h(S.value, (e) => (f(), r(vt, {
|
|
741
|
-
key: e.id,
|
|
742
|
-
tile: e,
|
|
743
|
-
variant: "results"
|
|
744
|
-
}, null, 8, ["tile"]))), 128))])) : g.value ? (f(), a("p", zt, v(y(s)("publications.results.none")), 1)) : (f(), a("p", Bt, v(y(s)("publications.results.reset")), 1)),
|
|
745
|
-
c($, {
|
|
746
|
-
"page-info": x.value,
|
|
747
|
-
onNavigate: w
|
|
748
|
-
}, null, 8, ["page-info"])
|
|
749
|
-
]));
|
|
750
|
-
}
|
|
751
|
-
}, Ht = { class: "mwnf-books-publication" }, Ut = {
|
|
752
|
-
key: 0,
|
|
753
|
-
class: "mwnf-books-list__empty"
|
|
754
|
-
}, Wt = { class: "mwnf-books-publication__header" }, Gt = {
|
|
755
|
-
key: 0,
|
|
756
|
-
class: "mwnf-books-publication__category"
|
|
757
|
-
}, Kt = { class: "mwnf-books-publication__language" }, qt = { class: "mwnf-books-publication__versions" }, Jt = ["aria-pressed", "onClick"], Yt = ["dir", "lang"], Xt = { class: "mwnf-books-edition__cover-column" }, Zt = {
|
|
758
|
-
key: 0,
|
|
759
|
-
class: "mwnf-books-edition__cover"
|
|
760
|
-
}, Qt = ["src"], $t = {
|
|
761
|
-
key: 1,
|
|
762
|
-
class: "mwnf-books-edition__cover mwnf-books-edition__cover--none"
|
|
763
|
-
}, en = { class: "mwnf-books-edition__cover-info" }, tn = { key: 0 }, nn = {
|
|
764
|
-
key: 1,
|
|
765
|
-
class: "mwnf-books-edition__format"
|
|
766
|
-
}, rn = { key: 0 }, an = {
|
|
767
|
-
key: 2,
|
|
768
|
-
class: "mwnf-books-edition__pdf"
|
|
769
|
-
}, on = ["href"], sn = {
|
|
770
|
-
key: 3,
|
|
771
|
-
class: "mwnf-books-edition__pdf"
|
|
772
|
-
}, cn = ["href"], ln = { class: "mwnf-books-edition__information" }, un = { class: "mwnf-books-edition__group" }, dn = {
|
|
773
|
-
key: 0,
|
|
774
|
-
class: "mwnf-books-edition__country"
|
|
775
|
-
}, fn = {
|
|
776
|
-
key: 1,
|
|
777
|
-
class: "mwnf-books-edition__project"
|
|
778
|
-
}, pn = { class: "mwnf-books-edition__group" }, mn = {
|
|
779
|
-
key: 0,
|
|
780
|
-
class: "mwnf-books-edition__title"
|
|
781
|
-
}, hn = {
|
|
782
|
-
key: 1,
|
|
783
|
-
class: "mwnf-books-edition__subtitle"
|
|
784
|
-
}, gn = { class: "mwnf-books-edition__group" }, _n = { key: 0 }, vn = { key: 1 }, yn = { key: 2 }, bn = { key: 3 }, xn = { key: 4 }, Sn = {
|
|
785
|
-
key: 5,
|
|
786
|
-
class: "mwnf-books-edition__plans"
|
|
787
|
-
}, Cn = { class: "mwnf-books-edition__group" }, wn = {
|
|
788
|
-
key: 0,
|
|
789
|
-
class: "mwnf-books-edition__publisher"
|
|
790
|
-
}, Tn = {
|
|
791
|
-
key: 1,
|
|
792
|
-
class: "mwnf-books-edition__isbn"
|
|
793
|
-
}, En = {
|
|
794
|
-
key: 0,
|
|
795
|
-
class: "mwnf-books-edition__about"
|
|
796
|
-
}, Dn = { class: "mwnf-books-edition__about-header" }, On = ["innerHTML"], kn = {
|
|
797
|
-
key: 1,
|
|
798
|
-
class: "mwnf-books-edition__more-about"
|
|
799
|
-
}, An = ["aria-expanded"], jn = ["innerHTML"], Mn = ["innerHTML"], Nn = ["dir", "lang"], Pn = { class: "mwnf-books-editions__information" }, Fn = {
|
|
800
|
-
key: 0,
|
|
801
|
-
class: "mwnf-books-editions__subtitle"
|
|
802
|
-
}, In = [
|
|
803
|
-
"aria-pressed",
|
|
804
|
-
"onClick",
|
|
805
|
-
"onKeydown"
|
|
806
|
-
], Ln = {
|
|
807
|
-
key: 0,
|
|
808
|
-
class: "mwnf-books-editions__image"
|
|
809
|
-
}, Rn = ["src"], zn = { class: "mwnf-books-editions__group" }, Bn = { key: 0 }, Vn = {
|
|
810
|
-
key: 1,
|
|
811
|
-
class: "mwnf-books-editions__format"
|
|
812
|
-
}, Hn = { key: 2 }, Un = { key: 3 }, Wn = { key: 4 }, Gn = { key: 5 }, Kn = { class: "mwnf-books-editions__group" }, qn = {
|
|
813
|
-
key: 0,
|
|
814
|
-
class: "mwnf-books-edition__pdf"
|
|
815
|
-
}, Jn = ["href"], Yn = {
|
|
816
|
-
key: 1,
|
|
817
|
-
class: "mwnf-books-edition__pdf"
|
|
818
|
-
}, Xn = ["href"], Zn = {
|
|
819
|
-
__name: "Publication",
|
|
820
|
-
props: {
|
|
821
|
-
id: {
|
|
822
|
-
type: String,
|
|
823
|
-
required: !0
|
|
824
|
-
},
|
|
825
|
-
language: {
|
|
826
|
-
type: String,
|
|
827
|
-
default: ""
|
|
828
|
-
}
|
|
829
|
-
},
|
|
830
|
-
setup(e) {
|
|
831
|
-
let r = e, { t: c, tIn: u } = I(), d = z(), p = D("editions"), g = n(() => D("publications").value.get(r.id) ?? null), _ = Z({ languagesToLoad: () => g.value ? K(g.value, p.value) : [] }), b = n(() => g.value ? K(g.value, _.editionById.value) : []), x = n(() => g.value ? q(g.value, _.editionById.value, r.language || null) : "en"), w = n(() => te(x.value) ? "rtl" : "ltr"), O = (e) => u(x.value, e), k = n(() => g.value ? ce(g.value, _.editionById.value, x.value) : []), A = m(0);
|
|
832
|
-
C([() => r.id, x], () => {
|
|
833
|
-
A.value = 0;
|
|
834
|
-
});
|
|
835
|
-
let j = n(() => k.value[A.value] ?? k.value[0] ?? null), M = n(() => g.value ? _.text(g.value, x.value) : {}), P = n(() => k.value.map((e) => ue(M.value, e))), F = n(() => P.value[A.value] ?? ue(M.value, null)), L = n(() => J(j.value)), R = n(() => j.value?.cover?.url ?? (k.value.length ? null : g.value?.cover?.url ?? null)), B = n(() => {
|
|
836
|
-
let e = _.categories.value.find((e) => e.category && e.category === g.value?.category);
|
|
837
|
-
return e ? c(e.label) : "";
|
|
838
|
-
}), ne = n(() => [j.value?.publish_year, O("publications.edition.languageVersion")].filter(Y).join(", ")), V = m(!1), H = (e) => Y(e) ? N(String(e), { breaks: !0 }) : "";
|
|
839
|
-
function U(e) {
|
|
840
|
-
e !== x.value && d.replace({
|
|
841
|
-
name: "publication",
|
|
842
|
-
params: {
|
|
843
|
-
id: r.id,
|
|
844
|
-
language: e
|
|
845
|
-
}
|
|
846
|
-
});
|
|
847
|
-
}
|
|
848
|
-
function W(e) {
|
|
849
|
-
if (A.value = e, V.value = !1, typeof window < "u" && typeof window.scrollTo == "function") try {
|
|
850
|
-
window.scrollTo({
|
|
851
|
-
top: 0,
|
|
852
|
-
behavior: "smooth"
|
|
853
|
-
});
|
|
854
|
-
} catch {}
|
|
855
|
-
}
|
|
856
|
-
return (e, n) => (f(), a("div", Ht, [g.value ? (f(), a(t, { key: 1 }, [
|
|
857
|
-
o("div", Wt, [B.value ? (f(), a("span", Gt, v(B.value) + ", ", 1)) : i("", !0), o("span", Kt, v(O("publications.edition.languageVersion")), 1)]),
|
|
858
|
-
o("div", qt, [s(v(O("publications.publication.languages")) + ": ", 1), (f(!0), a(t, null, h(b.value, (e) => (f(), a("button", {
|
|
859
|
-
key: e,
|
|
860
|
-
type: "button",
|
|
861
|
-
class: l(["mwnf-books-publication__version", { "mwnf-books-publication__version--current": e === x.value }]),
|
|
862
|
-
"aria-pressed": e === x.value,
|
|
863
|
-
onClick: (t) => U(e)
|
|
864
|
-
}, v(y(_).languageName(e)), 11, Jt))), 128))]),
|
|
865
|
-
o("div", {
|
|
866
|
-
class: "mwnf-books-edition",
|
|
867
|
-
dir: w.value,
|
|
868
|
-
lang: x.value
|
|
869
|
-
}, [o("div", Xt, [R.value ? (f(), a("div", Zt, [o("img", {
|
|
870
|
-
src: R.value,
|
|
871
|
-
alt: ""
|
|
872
|
-
}, null, 8, Qt)])) : (f(), a("div", $t, v(y(c)("publications.card.imageComingSoon")), 1)), o("div", en, [
|
|
873
|
-
ne.value ? (f(), a("div", tn, v(ne.value), 1)) : i("", !0),
|
|
874
|
-
y(Y)(j.value?.binding) ? (f(), a("div", nn, [s(v(j.value.binding), 1), y(Y)(j.value.dimensions) ? (f(), a("span", rn, " (" + v(j.value.dimensions) + ")", 1)) : i("", !0)])) : i("", !0),
|
|
875
|
-
L.value.sample ? (f(), a("div", an, [o("a", {
|
|
876
|
-
href: L.value.sample,
|
|
877
|
-
target: "_blank",
|
|
878
|
-
rel: "noopener"
|
|
879
|
-
}, v(O("publications.edition.lookInside")), 9, on)])) : i("", !0),
|
|
880
|
-
L.value.credits ? (f(), a("div", sn, [o("a", {
|
|
881
|
-
href: L.value.credits,
|
|
882
|
-
target: "_blank",
|
|
883
|
-
rel: "noopener"
|
|
884
|
-
}, v(O("publications.edition.credits")), 9, cn)])) : i("", !0)
|
|
885
|
-
])]), o("div", ln, [
|
|
886
|
-
o("div", un, [y(_).countryName(g.value.country_id) ? (f(), a("div", dn, v(y(_).countryName(g.value.country_id)), 1)) : i("", !0), y(_).projectName(g.value.project_id) ? (f(), a("div", fn, v(y(_).projectName(g.value.project_id)), 1)) : i("", !0)]),
|
|
887
|
-
o("div", pn, [y(Y)(F.value.title) ? (f(), a("div", mn, v(String(F.value.title).toUpperCase()), 1)) : i("", !0), y(Y)(F.value.subtitle) ? (f(), a("div", hn, v(F.value.subtitle), 1)) : i("", !0)]),
|
|
888
|
-
o("div", gn, [
|
|
889
|
-
y(Y)(F.value.authors) ? (f(), a("div", _n, v(O("publications.edition.authors")) + ": " + v(F.value.authors), 1)) : i("", !0),
|
|
890
|
-
y(Y)(F.value.photographers) ? (f(), a("div", vn, v(O("publications.edition.photographers")) + ": " + v(F.value.photographers), 1)) : i("", !0),
|
|
891
|
-
y(Y)(F.value.editors) ? (f(), a("div", yn, v(O("publications.edition.editors")) + ": " + v(F.value.editors), 1)) : i("", !0),
|
|
892
|
-
y(Y)(F.value.pages) ? (f(), a("div", bn, v(O("publications.edition.pages")) + ": " + v(F.value.pages), 1)) : i("", !0),
|
|
893
|
-
y(Y)(F.value.images) ? (f(), a("div", xn, v(O("publications.edition.images")) + ": " + v(F.value.images), 1)) : i("", !0),
|
|
894
|
-
y(Y)(F.value.plans) ? (f(), a("div", Sn, v(O("publications.edition.plans")) + ": " + v(F.value.plans), 1)) : i("", !0)
|
|
895
|
-
]),
|
|
896
|
-
o("div", Cn, [y(Y)(j.value?.publisher) ? (f(), a("div", wn, v(O("publications.edition.publishers")) + ": " + v(j.value.publisher), 1)) : i("", !0), y(Y)(j.value?.isbn) ? (f(), a("div", Tn, v(O("publications.edition.isbn")) + ": " + v(j.value.isbn), 1)) : i("", !0)]),
|
|
897
|
-
y(Y)(F.value.about) ? (f(), a("div", En, [o("div", Dn, v(O("publications.edition.about")), 1), o("div", {
|
|
898
|
-
class: "mwnf-books-edition__prose",
|
|
899
|
-
innerHTML: H(F.value.about)
|
|
900
|
-
}, null, 8, On)])) : i("", !0),
|
|
901
|
-
y(Y)(F.value.moreAbout) ? (f(), a("div", kn, [o("button", {
|
|
902
|
-
type: "button",
|
|
903
|
-
class: "mwnf-books-edition__more-about-header",
|
|
904
|
-
"aria-expanded": V.value,
|
|
905
|
-
onClick: n[0] ||= (e) => V.value = !V.value
|
|
906
|
-
}, v(O("publications.edition.moreAbout")), 9, An), T(o("div", {
|
|
907
|
-
class: "mwnf-books-edition__prose",
|
|
908
|
-
innerHTML: H(F.value.moreAbout)
|
|
909
|
-
}, null, 8, jn), [[S, V.value]])])) : i("", !0),
|
|
910
|
-
y(Y)(F.value.note) ? (f(), a("div", {
|
|
911
|
-
key: 2,
|
|
912
|
-
class: "mwnf-books-edition__note mwnf-books-edition__prose",
|
|
913
|
-
innerHTML: H(F.value.note)
|
|
914
|
-
}, null, 8, Mn)) : i("", !0)
|
|
915
|
-
])], 8, Yt),
|
|
916
|
-
k.value.length > 1 ? (f(), a("div", {
|
|
917
|
-
key: 0,
|
|
918
|
-
class: "mwnf-books-editions",
|
|
919
|
-
dir: w.value,
|
|
920
|
-
lang: x.value
|
|
921
|
-
}, [o("div", Pn, [
|
|
922
|
-
s(v(O("publications.edition.editionsOf")) + " ", 1),
|
|
923
|
-
o("span", null, v(F.value.title) + ". ", 1),
|
|
924
|
-
y(Y)(F.value.subtitle) ? (f(), a("span", Fn, v(F.value.subtitle) + ", ", 1)) : i("", !0),
|
|
925
|
-
s(v(O("publications.edition.languageVersion")), 1)
|
|
926
|
-
]), o("div", { class: l(["mwnf-books-editions__list", { "mwnf-books-editions__list--scroll": k.value.length > 4 }]) }, [(f(!0), a(t, null, h(k.value, (e, t) => (f(), a("div", {
|
|
927
|
-
key: e.id,
|
|
928
|
-
class: l(["mwnf-books-editions__item", { "mwnf-books-editions__item--current": t === A.value }]),
|
|
929
|
-
role: "button",
|
|
930
|
-
tabindex: "0",
|
|
931
|
-
"aria-pressed": t === A.value,
|
|
932
|
-
onClick: (e) => W(t),
|
|
933
|
-
onKeydown: ee(E((e) => W(t), ["prevent"]), ["enter"])
|
|
934
|
-
}, [
|
|
935
|
-
e.cover ? (f(), a("div", Ln, [o("img", {
|
|
936
|
-
src: e.cover.url,
|
|
937
|
-
alt: "",
|
|
938
|
-
loading: "lazy"
|
|
939
|
-
}, null, 8, Rn)])) : i("", !0),
|
|
940
|
-
o("div", zn, [
|
|
941
|
-
y(Y)(e.publisher) ? (f(), a("div", Bn, v(O("publications.edition.publishers")) + ": " + v(e.publisher), 1)) : i("", !0),
|
|
942
|
-
y(Y)(e.binding) ? (f(), a("div", Vn, v(e.binding), 1)) : i("", !0),
|
|
943
|
-
y(Y)(e.dimensions) ? (f(), a("div", Hn, v(e.dimensions), 1)) : i("", !0),
|
|
944
|
-
y(Y)(e.isbn) ? (f(), a("div", Un, v(e.isbn), 1)) : i("", !0),
|
|
945
|
-
y(Y)(e.publish_year) ? (f(), a("div", Wn, v(e.publish_year), 1)) : i("", !0),
|
|
946
|
-
y(Y)(e.edition) ? (f(), a("div", Gn, v(O("publications.edition.edition")) + ": " + v(e.edition), 1)) : i("", !0)
|
|
947
|
-
]),
|
|
948
|
-
o("div", Kn, [y(J)(e).sample ? (f(), a("div", qn, [o("a", {
|
|
949
|
-
href: y(J)(e).sample,
|
|
950
|
-
target: "_blank",
|
|
951
|
-
rel: "noopener",
|
|
952
|
-
onClick: n[1] ||= E(() => {}, ["stop"])
|
|
953
|
-
}, v(O("publications.edition.lookInside")), 9, Jn)])) : i("", !0), y(J)(e).credits ? (f(), a("div", Yn, [o("a", {
|
|
954
|
-
href: y(J)(e).credits,
|
|
955
|
-
target: "_blank",
|
|
956
|
-
rel: "noopener",
|
|
957
|
-
onClick: n[2] ||= E(() => {}, ["stop"])
|
|
958
|
-
}, v(O("publications.edition.credits")), 9, Xn)])) : i("", !0)])
|
|
959
|
-
], 42, In))), 128))], 2)], 8, Nn)) : i("", !0)
|
|
960
|
-
], 64)) : (f(), a("p", Ut, v(y(c)("core.detail.notFound")), 1))]));
|
|
961
|
-
}
|
|
962
|
-
};
|
|
963
|
-
// src/publications/routes.js
|
|
964
|
-
function Qn(e = P()) {
|
|
965
|
-
return [
|
|
966
|
-
{
|
|
967
|
-
path: "/",
|
|
968
|
-
name: "home",
|
|
969
|
-
component: St,
|
|
970
|
-
meta: e("home", ...B)
|
|
971
|
-
},
|
|
972
|
-
{
|
|
973
|
-
path: "/category/:category",
|
|
974
|
-
name: "category",
|
|
975
|
-
component: Pt,
|
|
976
|
-
props: (e) => ({ category: String(e.params.category) }),
|
|
977
|
-
meta: e("category", ...B)
|
|
978
|
-
},
|
|
979
|
-
{
|
|
980
|
-
path: "/results",
|
|
981
|
-
name: "results",
|
|
982
|
-
component: Vt,
|
|
983
|
-
meta: e("results", ...B)
|
|
984
|
-
},
|
|
985
|
-
{
|
|
986
|
-
path: "/publication/:id/:language?",
|
|
987
|
-
name: "publication",
|
|
988
|
-
component: Zn,
|
|
989
|
-
props: (e) => ({
|
|
990
|
-
id: String(e.params.id),
|
|
991
|
-
language: String(e.params.language ?? "")
|
|
992
|
-
}),
|
|
993
|
-
meta: e("publication", ...B)
|
|
994
|
-
}
|
|
995
|
-
];
|
|
996
|
-
}
|
|
997
|
-
function $n({ datasetPackage: e, origin: t, siteName: n, chrome: r = {}, publications: i = {} }) {
|
|
998
|
-
let { manifest: a } = F(), o = j({
|
|
999
|
-
declared: ["en"],
|
|
1000
|
-
entity: "publications"
|
|
1001
|
-
});
|
|
1002
|
-
return {
|
|
1003
|
-
datasetPackage: e,
|
|
1004
|
-
siteName: a.site?.names?.en ?? n ?? e,
|
|
1005
|
-
site: { origin: t },
|
|
1006
|
-
features: { entities: [] },
|
|
1007
|
-
languages: o,
|
|
1008
|
-
chrome: r,
|
|
1009
|
-
publications: i,
|
|
1010
|
-
shell: rt,
|
|
1011
|
-
navigation: { languages: k(o) },
|
|
1012
|
-
views: { home: St },
|
|
1013
|
-
extraViews: Qn(P()),
|
|
1014
|
-
legacyRoutes: []
|
|
1015
|
-
};
|
|
1016
|
-
}
|
|
1017
|
-
export { W as FORMATS, ne as PAGE_SIZE, xe as PUBLICATIONS_FOOTER, V as PUBLICATION_CATEGORIES, B as PUBLICATION_ENTITIES, Zn as PublicationPage, vt as PublicationTile, Pt as PublicationsCategory, St as PublicationsHome, $ as PublicationsPagination, Vt as PublicationsResults, rt as PublicationsShell, U as SEARCH_KEYS, K as availableLanguages, be as categoriesOf, ie as categoryBySlug, q as displayLanguage, J as documentsOf, ue as editionText, ce as editionsByYear, G as editionsOf, le as formatsOf, pe as hasSearch, H as homeLimit, re as inCategory, ae as limitLanguages, Y as present, $n as publicationsConfig, Qn as publicationsRoutes, me as searchPublications, de as themeKey, oe as truncate, Z as usePublications };
|