@museumwnf/viewer-layout 3.3.0 → 3.5.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 +191 -12
- package/dist/{FeaturedRecord-BJ8LaWGP.js → FeaturedRecord-DJfyvfqt.js} +1 -1
- package/dist/GlossaryPopover-DcptyNWI.js +654 -0
- package/dist/ItemDetailView-COWC8GDg.js +299 -0
- package/dist/{OnDisplayIn-Dv8i7uvH.js → OnDisplayIn-BfJoPonn.js} +38 -38
- package/dist/RecordView-C9rP8TyQ.js +263 -0
- package/dist/SiteShell-4vV2jIzf.js +192 -0
- package/dist/{Theme-Db88mckV.js → Theme-CZ-OVXao.js} +26 -26
- package/dist/TimelineEventList-gsoc-SBx.js +841 -0
- package/dist/TimelineResultsView-C2-TnM71.js +1386 -0
- package/dist/chrome-DPuPeWzV.js +1141 -0
- package/dist/components.js +1 -1
- package/dist/{content-p0tqKkcD.js → content-CtwBcSjU.js} +2 -2
- package/dist/content.js +6 -5
- package/dist/data-CJlLA-Mf.js +38 -0
- package/dist/data-DTbAYdr2.js +40 -0
- package/dist/dxa.js +638 -519
- package/dist/index.js +7 -6
- package/dist/standalone.js +762 -0
- package/dist/{themeSpecs-C_uGarTs.js → themeSpecs-B885l456.js} +3 -2
- package/dist/viewer-layout.css +1 -1
- package/dist/views.js +5 -4
- package/package.json +4 -3
- package/src/dxa/testing.js +37 -14
- package/src/styles/dxa-exhibition.css +25 -1
- package/src/styles/dxa-gallery.css +249 -2
- package/src/tokens.reference.css +78 -0
- package/dist/ItemDetailView-CfUtRLOV.js +0 -284
- package/dist/PageShell-CbJ9lQoQ.js +0 -961
- package/dist/SiteShell-C3OgZO8p.js +0 -154
- package/dist/TimelineEventList-COjkXEzS.js +0 -1487
- package/dist/TimelineResultsView-CmHomvV_.js +0 -1636
- package/dist/data-BfyYB8ff.js +0 -33
- package/dist/data-G8uXeEfE.js +0 -35
|
@@ -0,0 +1,263 @@
|
|
|
1
|
+
import { a as e, c as t, d as n, i as r, n as ee, o as te, r as ne, s as re, t as i } from "./GlossaryPopover-DcptyNWI.js";
|
|
2
|
+
import { Fragment as a, computed as o, createBlock as s, createCommentVNode as c, createElementBlock as l, createElementVNode as u, createSlots as d, createTextVNode as f, createVNode as p, guardReactiveProps as m, normalizeClass as ie, normalizeProps as h, openBlock as g, renderList as _, renderSlot as v, toDisplayString as y, unref as b, useSlots as x, withCtx as S } from "vue";
|
|
3
|
+
import { NotFoundView as ae, byId as oe, citation as se, entityRef as ce, languageLabels as le, renderBlock as C, renderInline as w, renderPlain as T, sheetRows as E, sourceUrl as ue, useDataPackage as de, useGlossaryPopup as fe, useI18n as pe, useProjects as me, useRecordSheet as he, useRelatedRecords as ge } from "@museumwnf/viewer-core";
|
|
4
|
+
import { useRoute as _e } from "vue-router";
|
|
5
|
+
//#region src/views/RecordView.vue
|
|
6
|
+
var ve = ["dir", "innerHTML"], ye = { class: "mwnf-record__body" }, be = { class: "mwnf-record__main" }, xe = {
|
|
7
|
+
key: 1,
|
|
8
|
+
class: "mwnf-record__status"
|
|
9
|
+
}, D = {
|
|
10
|
+
key: 0,
|
|
11
|
+
class: "mwnf-record__aside"
|
|
12
|
+
}, O = {
|
|
13
|
+
key: 2,
|
|
14
|
+
class: "mwnf-record__status"
|
|
15
|
+
}, k = {
|
|
16
|
+
__name: "RecordView",
|
|
17
|
+
props: {
|
|
18
|
+
spec: {
|
|
19
|
+
type: Object,
|
|
20
|
+
required: !0
|
|
21
|
+
},
|
|
22
|
+
id: {
|
|
23
|
+
type: String,
|
|
24
|
+
required: !0
|
|
25
|
+
},
|
|
26
|
+
entity: {
|
|
27
|
+
type: String,
|
|
28
|
+
default: ""
|
|
29
|
+
}
|
|
30
|
+
},
|
|
31
|
+
setup(k) {
|
|
32
|
+
let A = k, { t: j, locale: Se } = pe(), M = de(), Ce = me(), we = x(), Te = _e(), N = A.spec.entity ?? A.entity, P = o(() => A.spec), Ee = ce(N), De = oe(N), F = o(() => De.value.get(A.id) ?? null), Oe = o(() => Ee.value !== null), { language: I, languages: ke, dir: L, select: R, text: z, ready: B, terms: Ae, glossary: V, attribution: H } = he(F, {
|
|
33
|
+
entity: N,
|
|
34
|
+
translations: A.spec.translations ?? [],
|
|
35
|
+
attribution: A.spec.attribution ?? []
|
|
36
|
+
}), U = o(() => le(ke.value)), { active: W, onClick: G, close: je } = fe(Ae), Me = o(() => W.value ? C(W.value.definition, { breaks: !0 }) : ""), K = (e, t) => M.tr(e, t, I.value, "en"), q = o(() => ({
|
|
37
|
+
record: F.value,
|
|
38
|
+
text: z.value,
|
|
39
|
+
language: I.value,
|
|
40
|
+
languages: U.value,
|
|
41
|
+
select: R,
|
|
42
|
+
dir: L.value,
|
|
43
|
+
glossary: V.value,
|
|
44
|
+
ready: B.value,
|
|
45
|
+
attribution: H.value,
|
|
46
|
+
t: j,
|
|
47
|
+
tr: K
|
|
48
|
+
}));
|
|
49
|
+
function J(e) {
|
|
50
|
+
return ((typeof e == "function" ? e(q.value) : e) ?? []).map((e) => ({
|
|
51
|
+
...e,
|
|
52
|
+
label: e.label ? j(e.label) : ""
|
|
53
|
+
}));
|
|
54
|
+
}
|
|
55
|
+
let Ne = o(() => F.value ? E(J(P.value.fields), q.value) : []), Pe = o(() => F.value ? E(J(P.value.sections).map((e) => ({
|
|
56
|
+
render: "block",
|
|
57
|
+
...e
|
|
58
|
+
})), q.value) : []), Y = o(() => P.value.shortDescription === !1 ? "" : P.value.shortDescription ?? "short_description"), Fe = o(() => {
|
|
59
|
+
let e = Y.value ? z.value[Y.value] : "";
|
|
60
|
+
return e ? { html: C(String(e), {
|
|
61
|
+
breaks: !0,
|
|
62
|
+
glossary: V.value
|
|
63
|
+
}) } : null;
|
|
64
|
+
}), Ie = o(() => {
|
|
65
|
+
if (!F.value) return "";
|
|
66
|
+
if (P.value.title) return P.value.title(q.value);
|
|
67
|
+
let e = z.value.name ?? F.value.internal_name ?? F.value.id;
|
|
68
|
+
return w(String(e), { glossary: V.value });
|
|
69
|
+
}), X = o(() => {
|
|
70
|
+
if (!F.value) return [];
|
|
71
|
+
if (P.value.media) return P.value.media(F.value, q.value);
|
|
72
|
+
let e = T(String(z.value.name ?? F.value.internal_name ?? ""));
|
|
73
|
+
return (F.value.images ?? []).map((t) => ({
|
|
74
|
+
url: t.url,
|
|
75
|
+
alt: t.captions?.[I.value] ?? e,
|
|
76
|
+
caption: t.captions?.[I.value] ?? t.captions?.en ?? "",
|
|
77
|
+
photographer: t.photographer ?? "",
|
|
78
|
+
copyright: t.copyright ?? ""
|
|
79
|
+
}));
|
|
80
|
+
}), Le = [
|
|
81
|
+
{
|
|
82
|
+
field: "author",
|
|
83
|
+
label: "sheet.field.preparedBy"
|
|
84
|
+
},
|
|
85
|
+
{
|
|
86
|
+
field: "copy_editor",
|
|
87
|
+
label: "sheet.field.copyeditedBy"
|
|
88
|
+
},
|
|
89
|
+
{
|
|
90
|
+
field: "translator",
|
|
91
|
+
label: "sheet.field.translationBy"
|
|
92
|
+
},
|
|
93
|
+
{
|
|
94
|
+
field: "translation_copy_editor",
|
|
95
|
+
label: "sheet.field.translationCopyeditedBy"
|
|
96
|
+
}
|
|
97
|
+
], Re = o(() => (P.value.credits ?? Le).map(({ field: e, label: t }) => ({
|
|
98
|
+
label: j(t),
|
|
99
|
+
value: z.value[e] ?? H.value[e] ?? ""
|
|
100
|
+
})).filter((e) => e.value)), ze = o(() => String(F.value?.[P.value.workingNumber ?? "mwnf_reference"] ?? "")), Be = o(() => {
|
|
101
|
+
let e = P.value.citation;
|
|
102
|
+
if (!F.value || e === !1) return "";
|
|
103
|
+
let t = typeof e?.project == "function" ? null : e?.project ?? F.value.project_id, n = typeof e?.project == "function" ? e.project(F.value, q.value) : Ce.label(t), r = e?.permalink === !1 ? void 0 : typeof e?.permalink == "string" ? e.permalink : ue(Te) ?? void 0;
|
|
104
|
+
return se({
|
|
105
|
+
author: z.value.author ?? H.value.author,
|
|
106
|
+
name: z.value.name ?? F.value.internal_name ?? "",
|
|
107
|
+
project: n,
|
|
108
|
+
permalink: r,
|
|
109
|
+
inWord: j("record.citation.in")
|
|
110
|
+
});
|
|
111
|
+
}), Z = ge(F, {
|
|
112
|
+
entity: N,
|
|
113
|
+
language: I
|
|
114
|
+
}), Q = o(() => P.value.related === !1 ? null : P.value.related ?? {}), $ = o(() => {
|
|
115
|
+
if (!Q.value) return [];
|
|
116
|
+
let e = Q.value.record ?? Ve;
|
|
117
|
+
return Z.value.inPackage.map((t) => e(t, q.value));
|
|
118
|
+
});
|
|
119
|
+
function Ve({ record: e, justification: t }) {
|
|
120
|
+
let n = K(N, e.id).name ?? e.internal_name ?? e.id;
|
|
121
|
+
return {
|
|
122
|
+
id: e.id,
|
|
123
|
+
image: e.images?.[0]?.url ?? "",
|
|
124
|
+
imageAlt: T(String(n)),
|
|
125
|
+
name: w(String(n)),
|
|
126
|
+
meta: t ? [t] : [],
|
|
127
|
+
badge: e.type ?? "",
|
|
128
|
+
to: {
|
|
129
|
+
name: P.value.route ?? (A.entity ? `${A.entity}-detail` : "item"),
|
|
130
|
+
params: { id: e.id }
|
|
131
|
+
}
|
|
132
|
+
};
|
|
133
|
+
}
|
|
134
|
+
let He = /* @__PURE__ */ new Set([
|
|
135
|
+
"header",
|
|
136
|
+
"before-sheet",
|
|
137
|
+
"after-sheet",
|
|
138
|
+
"aside",
|
|
139
|
+
"source",
|
|
140
|
+
"related",
|
|
141
|
+
"after",
|
|
142
|
+
"default"
|
|
143
|
+
]), Ue = o(() => Object.keys(we).filter((e) => !He.has(e)));
|
|
144
|
+
return (o, x) => Oe.value && !F.value ? (g(), s(b(ae), { key: 0 })) : F.value ? (g(), l("article", {
|
|
145
|
+
key: 1,
|
|
146
|
+
class: ie(["mwnf-record", { "mwnf-record--spaced": P.value.spaced }]),
|
|
147
|
+
onClick: x[0] ||= (...e) => b(G) && b(G)(...e)
|
|
148
|
+
}, [
|
|
149
|
+
v(o.$slots, "header", h(m(q.value)), () => [
|
|
150
|
+
P.value.back ? (g(), s(n, {
|
|
151
|
+
key: 0,
|
|
152
|
+
class: "mwnf-record__back",
|
|
153
|
+
to: P.value.back.to,
|
|
154
|
+
href: P.value.back.href
|
|
155
|
+
}, {
|
|
156
|
+
default: S(() => [f("← " + y(b(j)(P.value.back.label)), 1)]),
|
|
157
|
+
_: 1
|
|
158
|
+
}, 8, ["to", "href"])) : c("", !0),
|
|
159
|
+
p(t, {
|
|
160
|
+
languages: U.value,
|
|
161
|
+
language: b(I),
|
|
162
|
+
onSelect: b(R)
|
|
163
|
+
}, null, 8, [
|
|
164
|
+
"languages",
|
|
165
|
+
"language",
|
|
166
|
+
"onSelect"
|
|
167
|
+
]),
|
|
168
|
+
u("h1", {
|
|
169
|
+
class: "mwnf-record__title",
|
|
170
|
+
dir: b(L) || void 0,
|
|
171
|
+
innerHTML: Ie.value
|
|
172
|
+
}, null, 8, ve)
|
|
173
|
+
]),
|
|
174
|
+
u("div", ye, [u("div", be, [
|
|
175
|
+
X.value.length ? (g(), s(ee, {
|
|
176
|
+
key: 0,
|
|
177
|
+
images: X.value,
|
|
178
|
+
variant: P.value.mediaVariant ?? ""
|
|
179
|
+
}, null, 8, ["images", "variant"])) : c("", !0),
|
|
180
|
+
b(B) ? c("", !0) : (g(), l("p", xe, y(b(j)("core.status.loading")), 1)),
|
|
181
|
+
v(o.$slots, "before-sheet", h(m(q.value))),
|
|
182
|
+
p(re, {
|
|
183
|
+
rows: Ne.value,
|
|
184
|
+
layout: P.value.layout ?? "table",
|
|
185
|
+
dir: b(L),
|
|
186
|
+
"short-description": Fe.value,
|
|
187
|
+
"short-description-after": P.value.shortDescriptionAfter ?? "description"
|
|
188
|
+
}, d({ _: 2 }, [_(Ue.value, (e) => ({
|
|
189
|
+
name: e,
|
|
190
|
+
fn: S((t) => [v(o.$slots, e, h(m({
|
|
191
|
+
...t,
|
|
192
|
+
...q.value
|
|
193
|
+
})))])
|
|
194
|
+
}))]), 1032, [
|
|
195
|
+
"rows",
|
|
196
|
+
"layout",
|
|
197
|
+
"dir",
|
|
198
|
+
"short-description",
|
|
199
|
+
"short-description-after"
|
|
200
|
+
]),
|
|
201
|
+
(g(!0), l(a, null, _(Pe.value, (e) => (g(), s(te, {
|
|
202
|
+
key: e.key,
|
|
203
|
+
heading: e.label,
|
|
204
|
+
html: e.html,
|
|
205
|
+
dir: b(L)
|
|
206
|
+
}, null, 8, [
|
|
207
|
+
"heading",
|
|
208
|
+
"html",
|
|
209
|
+
"dir"
|
|
210
|
+
]))), 128)),
|
|
211
|
+
v(o.$slots, "after-sheet", h(m(q.value))),
|
|
212
|
+
p(e, {
|
|
213
|
+
credits: Re.value,
|
|
214
|
+
"working-number": ze.value,
|
|
215
|
+
"working-number-label": b(j)("sheet.field.workingNumber"),
|
|
216
|
+
citation: Be.value,
|
|
217
|
+
"citation-heading": P.value.citation?.heading ? b(j)(P.value.citation.heading) : ""
|
|
218
|
+
}, null, 8, [
|
|
219
|
+
"credits",
|
|
220
|
+
"working-number",
|
|
221
|
+
"working-number-label",
|
|
222
|
+
"citation",
|
|
223
|
+
"citation-heading"
|
|
224
|
+
]),
|
|
225
|
+
v(o.$slots, "source", h(m(q.value)), () => [p(r)]),
|
|
226
|
+
v(o.$slots, "related", h(m({
|
|
227
|
+
...q.value,
|
|
228
|
+
records: $.value,
|
|
229
|
+
outside: b(Z).outside
|
|
230
|
+
})), () => [Q.value ? (g(), s(ne, {
|
|
231
|
+
key: 0,
|
|
232
|
+
heading: b(j)(Q.value.heading ?? "record.related.items"),
|
|
233
|
+
records: $.value,
|
|
234
|
+
variant: Q.value.variant ?? "list",
|
|
235
|
+
"action-label": Q.value.actionLabel ? b(j)(Q.value.actionLabel) : ""
|
|
236
|
+
}, null, 8, [
|
|
237
|
+
"heading",
|
|
238
|
+
"records",
|
|
239
|
+
"variant",
|
|
240
|
+
"action-label"
|
|
241
|
+
])) : c("", !0)])
|
|
242
|
+
]), o.$slots.aside ? (g(), l("aside", D, [v(o.$slots, "aside", h(m({
|
|
243
|
+
...q.value,
|
|
244
|
+
records: $.value,
|
|
245
|
+
outside: b(Z).outside
|
|
246
|
+
})))])) : c("", !0)]),
|
|
247
|
+
v(o.$slots, "after", h(m(q.value))),
|
|
248
|
+
p(i, {
|
|
249
|
+
term: b(W),
|
|
250
|
+
html: Me.value,
|
|
251
|
+
dir: b(L),
|
|
252
|
+
onClose: b(je)
|
|
253
|
+
}, null, 8, [
|
|
254
|
+
"term",
|
|
255
|
+
"html",
|
|
256
|
+
"dir",
|
|
257
|
+
"onClose"
|
|
258
|
+
])
|
|
259
|
+
], 2)) : (g(), l("p", O, y(b(j)("core.status.loading")), 1));
|
|
260
|
+
}
|
|
261
|
+
};
|
|
262
|
+
//#endregion
|
|
263
|
+
export { k as t };
|
|
@@ -0,0 +1,192 @@
|
|
|
1
|
+
import { a as e, r as t } from "./chrome-DPuPeWzV.js";
|
|
2
|
+
import { computed as n, createBlock as r, createSlots as i, mergeProps as a, openBlock as o, renderSlot as s, useAttrs as c, withCtx as l } from "vue";
|
|
3
|
+
import { mwnfLinks as u, useI18n as d, useSection as f, useSiteConfig as p, useSiteRights as m } from "@museumwnf/viewer-core";
|
|
4
|
+
import { useRouter as h } from "vue-router";
|
|
5
|
+
//#region src/components/SiteShell.vue
|
|
6
|
+
var g = /*@__PURE__*/ Object.assign({ inheritAttrs: !1 }, {
|
|
7
|
+
__name: "SiteShell",
|
|
8
|
+
props: {
|
|
9
|
+
config: {
|
|
10
|
+
type: Object,
|
|
11
|
+
default: null
|
|
12
|
+
},
|
|
13
|
+
logos: {
|
|
14
|
+
type: Array,
|
|
15
|
+
default: () => []
|
|
16
|
+
}
|
|
17
|
+
},
|
|
18
|
+
setup(g) {
|
|
19
|
+
let _ = g, { t: v, locale: y } = d(), b = h(), x = f(), S = p(), C = n(() => ({
|
|
20
|
+
...S,
|
|
21
|
+
..._.config ?? {}
|
|
22
|
+
})), w = n(() => C.value.navigation ?? {}), T = n(() => C.value.logos ?? null), E = n(() => C.value.banner ?? null), D = c(), O = [
|
|
23
|
+
{
|
|
24
|
+
label: "core.footer.aboutMwnf",
|
|
25
|
+
href: u.about,
|
|
26
|
+
external: !0
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
label: "core.footer.contact",
|
|
30
|
+
href: u.contact,
|
|
31
|
+
external: !0
|
|
32
|
+
},
|
|
33
|
+
{
|
|
34
|
+
label: "core.footer.legalNotice",
|
|
35
|
+
href: u.legalNotice,
|
|
36
|
+
external: !0
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
label: "core.footer.credits",
|
|
40
|
+
href: u.credits,
|
|
41
|
+
external: !0
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
label: "core.footer.cookies",
|
|
45
|
+
href: u.cookies,
|
|
46
|
+
external: !0
|
|
47
|
+
}
|
|
48
|
+
], k = (/* @__PURE__ */ new Date()).getFullYear(), A = n(() => D.footerText === void 0 && D["footer-text"] === void 0 ? `${v("core.footer.copyright")} 2004–${k}` : null), j = m(), M = n(() => C.value.footer?.rightsHolder !== !0 || !j.holder ? null : {
|
|
49
|
+
label: v("record.source.rightsHolder"),
|
|
50
|
+
text: j.attribution ?? j.holder,
|
|
51
|
+
termsHref: j.termsUrl,
|
|
52
|
+
termsLabel: v("record.source.termsOfUse")
|
|
53
|
+
});
|
|
54
|
+
function N(e) {
|
|
55
|
+
return e.href ? e.href : e.to ? b.resolve(e.to).href : "";
|
|
56
|
+
}
|
|
57
|
+
function P(e) {
|
|
58
|
+
return typeof e.when != "function" || !!e.when({
|
|
59
|
+
section: x.value,
|
|
60
|
+
locale: y.value
|
|
61
|
+
});
|
|
62
|
+
}
|
|
63
|
+
function F(e, { active: t = !1 } = {}) {
|
|
64
|
+
let n = {
|
|
65
|
+
label: v(e.label),
|
|
66
|
+
href: N(e),
|
|
67
|
+
external: !!e.external
|
|
68
|
+
};
|
|
69
|
+
return t && (n.active = e.section === x.value), n;
|
|
70
|
+
}
|
|
71
|
+
let I = n(() => Array.isArray(w.value.links) ? w.value.links.filter(P).map((e) => F(e, { active: !0 })) : null), L = n(() => Array.isArray(w.value.headerLinks) ? w.value.headerLinks.map((e) => F(e)) : null), R = n(() => (Array.isArray(w.value.footerLinks) ? w.value.footerLinks : O).map((e) => F(e))), z = n(() => {
|
|
72
|
+
let e = w.value.search;
|
|
73
|
+
return e ? {
|
|
74
|
+
placeholder: e.placeholder ? v(e.placeholder) : "",
|
|
75
|
+
submitLabel: e.submitLabel ? v(e.submitLabel) : ""
|
|
76
|
+
} : null;
|
|
77
|
+
});
|
|
78
|
+
function B(e) {
|
|
79
|
+
let t = w.value.search;
|
|
80
|
+
t?.route && b.push({
|
|
81
|
+
name: t.route,
|
|
82
|
+
query: { [t.key ?? "q"]: e || t.empty || "" }
|
|
83
|
+
});
|
|
84
|
+
}
|
|
85
|
+
function V(e) {
|
|
86
|
+
return typeof e == "function" ? e({
|
|
87
|
+
section: x.value,
|
|
88
|
+
locale: y.value,
|
|
89
|
+
t: v
|
|
90
|
+
}) : typeof e == "string" ? v(e) : e;
|
|
91
|
+
}
|
|
92
|
+
let H = n(() => {
|
|
93
|
+
let e = E.value ? V(E.value.title) : "";
|
|
94
|
+
if (e) return e;
|
|
95
|
+
let t = w.value.sectionTitles?.[x.value];
|
|
96
|
+
return t ? v(t) : "";
|
|
97
|
+
}), U = [
|
|
98
|
+
"variant",
|
|
99
|
+
"image",
|
|
100
|
+
"imageAlt",
|
|
101
|
+
"caption",
|
|
102
|
+
"captionLabel",
|
|
103
|
+
"subtitle",
|
|
104
|
+
"headline",
|
|
105
|
+
"enter",
|
|
106
|
+
"strapline"
|
|
107
|
+
], W = n(() => {
|
|
108
|
+
let e = {};
|
|
109
|
+
H.value && (e.bannerTitle = H.value);
|
|
110
|
+
for (let t of U) {
|
|
111
|
+
let n = E.value ? V(E.value[t]) : "";
|
|
112
|
+
n && (e[`banner${t[0].toUpperCase()}${t.slice(1)}`] = n);
|
|
113
|
+
}
|
|
114
|
+
return e;
|
|
115
|
+
}), G = n(() => {
|
|
116
|
+
let e = C.value.brand, n = e ? t(C.value.chrome, e.logo) : null;
|
|
117
|
+
return n ? {
|
|
118
|
+
src: n,
|
|
119
|
+
alt: e.alt ? v(e.alt) : ""
|
|
120
|
+
} : null;
|
|
121
|
+
}), K = n(() => {
|
|
122
|
+
let e = w.value.placement;
|
|
123
|
+
return typeof e == "function" ? e({
|
|
124
|
+
section: x.value,
|
|
125
|
+
locale: y.value
|
|
126
|
+
}) : e;
|
|
127
|
+
}), q = n(() => Array.isArray(w.value.socialLinks) ? w.value.socialLinks : null), J = n(() => {
|
|
128
|
+
let e = T.value?.header;
|
|
129
|
+
return typeof e == "function" ? _.logos.filter(e) : null;
|
|
130
|
+
}), Y = n(() => {
|
|
131
|
+
let e = T.value?.headerTitle;
|
|
132
|
+
return e && J.value?.length ? v(e) : "";
|
|
133
|
+
}), X = n(() => {
|
|
134
|
+
let e = T.value?.sponsorGroups;
|
|
135
|
+
return typeof e == "function" ? e(_.logos, v) : null;
|
|
136
|
+
}), Z = n(() => {
|
|
137
|
+
let e = { ...W.value };
|
|
138
|
+
return Array.isArray(w.value.languages) && (e.languages = w.value.languages), I.value && (e.navLinks = I.value), L.value && (e.headerLinks = L.value), R.value && (e.footerLinks = R.value), A.value && (e.footerText = A.value), z.value && (e.search = z.value), J.value && (e.headerLogos = J.value, Y.value && (e.headerLogosTitle = Y.value)), X.value && (e.sponsorGroups = X.value), G.value && (e.headerBrandLogo = G.value), K.value && (e.navigationPlacement = K.value), q.value && (e.footerSocial = q.value), M.value && (e.footerAttributionLabel = M.value.label, e.footerAttributionText = M.value.text, e.footerTermsHref = M.value.termsHref, e.footerTermsLabel = M.value.termsLabel), e;
|
|
139
|
+
});
|
|
140
|
+
return (t, n) => (o(), r(e, a({
|
|
141
|
+
...t.$attrs,
|
|
142
|
+
...Z.value
|
|
143
|
+
}, { onSearch: B }), i({ _: 2 }, [
|
|
144
|
+
t.$slots.header ? {
|
|
145
|
+
name: "header",
|
|
146
|
+
fn: l(() => [s(t.$slots, "header")]),
|
|
147
|
+
key: "0"
|
|
148
|
+
} : void 0,
|
|
149
|
+
t.$slots.brand ? {
|
|
150
|
+
name: "header-brand",
|
|
151
|
+
fn: l(() => [s(t.$slots, "brand")]),
|
|
152
|
+
key: "1"
|
|
153
|
+
} : void 0,
|
|
154
|
+
t.$slots.banner ? {
|
|
155
|
+
name: "banner",
|
|
156
|
+
fn: l(() => [s(t.$slots, "banner")]),
|
|
157
|
+
key: "2"
|
|
158
|
+
} : void 0,
|
|
159
|
+
t.$slots.navigation ? {
|
|
160
|
+
name: "navigation",
|
|
161
|
+
fn: l(() => [s(t.$slots, "navigation")]),
|
|
162
|
+
key: "3"
|
|
163
|
+
} : void 0,
|
|
164
|
+
t.$slots.default || t.$slots.notice || t.$slots["after-content"] ? {
|
|
165
|
+
name: "default",
|
|
166
|
+
fn: l(() => [
|
|
167
|
+
s(t.$slots, "notice"),
|
|
168
|
+
s(t.$slots, "default"),
|
|
169
|
+
s(t.$slots, "after-content")
|
|
170
|
+
]),
|
|
171
|
+
key: "4"
|
|
172
|
+
} : void 0,
|
|
173
|
+
t.$slots.hyperlinks ? {
|
|
174
|
+
name: "hyperlinks",
|
|
175
|
+
fn: l(() => [s(t.$slots, "hyperlinks")]),
|
|
176
|
+
key: "5"
|
|
177
|
+
} : void 0,
|
|
178
|
+
t.$slots.sponsors ? {
|
|
179
|
+
name: "sponsors",
|
|
180
|
+
fn: l(() => [s(t.$slots, "sponsors")]),
|
|
181
|
+
key: "6"
|
|
182
|
+
} : void 0,
|
|
183
|
+
t.$slots.footer ? {
|
|
184
|
+
name: "footer",
|
|
185
|
+
fn: l(() => [s(t.$slots, "footer")]),
|
|
186
|
+
key: "7"
|
|
187
|
+
} : void 0
|
|
188
|
+
]), 1040));
|
|
189
|
+
}
|
|
190
|
+
});
|
|
191
|
+
//#endregion
|
|
192
|
+
export { g as t };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { o as n } from "./TimelineResultsView-
|
|
3
|
-
import { A as r, F as i, h as a, m as o } from "./data-
|
|
4
|
-
import { n as s, r as c, t as l } from "./themeSpecs-
|
|
1
|
+
import { d as e, i as t } from "./GlossaryPopover-DcptyNWI.js";
|
|
2
|
+
import { o as n } from "./TimelineResultsView-C2-TnM71.js";
|
|
3
|
+
import { A as r, F as i, h as a, m as o } from "./data-CJlLA-Mf.js";
|
|
4
|
+
import { n as s, r as c, t as l } from "./themeSpecs-B885l456.js";
|
|
5
5
|
import { Fragment as u, computed as d, createBlock as f, createCommentVNode as p, createElementBlock as m, createElementVNode as h, createTextVNode as g, createVNode as _, normalizeClass as v, onMounted as ee, openBlock as y, ref as b, renderList as x, toDisplayString as S, unref as C, vModelCheckbox as w, watch as T, withCtx as E, withDirectives as D } from "vue";
|
|
6
6
|
import { renderBlock as O, useI18n as k } from "@museumwnf/viewer-core";
|
|
7
7
|
import { RouterLink as A, useRoute as te, useRouter as ne } from "vue-router";
|
|
@@ -67,8 +67,8 @@ var j = Object.defineProperty, M = (e, t) => {
|
|
|
67
67
|
}
|
|
68
68
|
},
|
|
69
69
|
emits: ["update:selectedId"],
|
|
70
|
-
setup(
|
|
71
|
-
let r =
|
|
70
|
+
setup(t, { emit: n }) {
|
|
71
|
+
let r = t, i = n, { t: a } = k(), o = d(() => r.pictures.find((e) => e.id === r.selectedId) ?? null), s = d(() => r.pictures.some((e) => e.backRelated?.length)), c = b(!1);
|
|
72
72
|
T(() => r.pictures, () => {
|
|
73
73
|
c.value = !1;
|
|
74
74
|
});
|
|
@@ -86,38 +86,38 @@ var j = Object.defineProperty, M = (e, t) => {
|
|
|
86
86
|
class: "mwnf-picture-gallery__detail"
|
|
87
87
|
}, [e.label ? (y(), m("span", B, S(e.label), 1)) : p("", !0), h("span", { innerHTML: e.value }, null, 8, V)]))), 128)),
|
|
88
88
|
o.value.detail ? (y(), m("div", H, S(o.value.detail), 1)) : p("", !0),
|
|
89
|
-
o.value.to ? (y(), f(
|
|
89
|
+
o.value.to ? (y(), f(e, {
|
|
90
90
|
key: 1,
|
|
91
91
|
class: "mwnf-picture-gallery__link",
|
|
92
92
|
to: o.value.to
|
|
93
93
|
}, {
|
|
94
|
-
default: E(() => [g(S(C(a)(
|
|
94
|
+
default: E(() => [g(S(C(a)(t.seeItemEntry)) + " →", 1)]),
|
|
95
95
|
_: 1
|
|
96
|
-
}, 8, ["to"])) : (y(), m("div", U, S(C(a)(
|
|
97
|
-
])])) : (y(), m("div", W, S(C(a)(
|
|
98
|
-
key:
|
|
96
|
+
}, 8, ["to"])) : (y(), m("div", U, S(C(a)(t.unresolvedEntry)), 1))
|
|
97
|
+
])])) : (y(), m("div", W, S(C(a)(t.emptyEntry)), 1)), t.pictures.length ? (y(), m("div", G, [h("ul", K, [(y(!0), m(u, null, x(l.value, (e) => (y(), m("li", {
|
|
98
|
+
key: e.id,
|
|
99
99
|
class: v(["mwnf-picture-gallery__thumb", {
|
|
100
|
-
"mwnf-picture-gallery__thumb--active":
|
|
101
|
-
"mwnf-picture-gallery__thumb--related":
|
|
100
|
+
"mwnf-picture-gallery__thumb--active": e.id === t.selectedId,
|
|
101
|
+
"mwnf-picture-gallery__thumb--related": e.backRelated?.length
|
|
102
102
|
}])
|
|
103
103
|
}, [h("button", {
|
|
104
104
|
type: "button",
|
|
105
|
-
onClick: (
|
|
105
|
+
onClick: (t) => _(e)
|
|
106
106
|
}, [h("img", {
|
|
107
|
-
src:
|
|
108
|
-
alt:
|
|
107
|
+
src: e.image,
|
|
108
|
+
alt: e.imageAlt ?? "",
|
|
109
109
|
loading: "lazy"
|
|
110
110
|
}, null, 8, J)], 8, q), h("div", Y, [
|
|
111
|
-
|
|
111
|
+
e.imageCaption ? (y(), m("span", X, S(e.imageCaption) + ", ", 1)) : p("", !0),
|
|
112
112
|
h("span", {
|
|
113
113
|
class: "mwnf-picture-gallery__thumb-name",
|
|
114
|
-
innerHTML:
|
|
114
|
+
innerHTML: e.name
|
|
115
115
|
}, null, 8, Z),
|
|
116
|
-
|
|
116
|
+
e.detail ? (y(), m("span", Q, ", " + S(e.detail), 1)) : p("", !0)
|
|
117
117
|
])], 2))), 128))]), s.value ? (y(), m("label", ie, [D(h("input", {
|
|
118
118
|
"onUpdate:modelValue": r[0] ||= (e) => c.value = e,
|
|
119
119
|
type: "checkbox"
|
|
120
|
-
}, null, 512), [[w, c.value]]), h("span", null, S(c.value ? C(a)(
|
|
120
|
+
}, null, 512), [[w, c.value]]), h("span", null, S(c.value ? C(a)(t.hideRelatedEntry) : C(a)(t.addRelatedEntry)), 1)])) : p("", !0)])) : p("", !0)]));
|
|
121
121
|
}
|
|
122
122
|
}, $ = {
|
|
123
123
|
key: 0,
|
|
@@ -211,8 +211,8 @@ var j = Object.defineProperty, M = (e, t) => {
|
|
|
211
211
|
type: Boolean,
|
|
212
212
|
default: !1
|
|
213
213
|
} },
|
|
214
|
-
setup(
|
|
215
|
-
let w =
|
|
214
|
+
setup(e) {
|
|
215
|
+
let w = e, { aboutTheme: D, owningTheme: O, romanFor: j, themeByRouteId: M, themeText: N, useThemePictures: re } = r, { t: P, locale: F } = k(), I = te(), L = ne(), R = d(() => w.aboutMode ? D.value : M(I.params.id)), z = d(() => {
|
|
216
216
|
let e = I.params.subtheme;
|
|
217
217
|
if (w.aboutMode || !e || e === "overview") return null;
|
|
218
218
|
let t = Number(e);
|
|
@@ -252,7 +252,7 @@ var j = Object.defineProperty, M = (e, t) => {
|
|
|
252
252
|
key: 0,
|
|
253
253
|
spec: H.value,
|
|
254
254
|
id: V.value.id,
|
|
255
|
-
class: v(["mwnf-dxa-theme", { "mwnf-dxa-theme--about":
|
|
255
|
+
class: v(["mwnf-dxa-theme", { "mwnf-dxa-theme--about": e.aboutMode }])
|
|
256
256
|
}, {
|
|
257
257
|
header: E(() => [h("div", je, [Q.value ? (y(), m("span", Me, S(C(P)("exhibition.theme.romanLabel")) + " " + S(Q.value) + " ▪ ", 1)) : p("", !0), g(S(X.value), 1)]), h("div", Ne, S(Z.value), 1)]),
|
|
258
258
|
panel: E(() => [_(ae, {
|
|
@@ -260,7 +260,7 @@ var j = Object.defineProperty, M = (e, t) => {
|
|
|
260
260
|
"selected-id": W.value,
|
|
261
261
|
"onUpdate:selectedId": J
|
|
262
262
|
}, null, 8, ["pictures", "selected-id"])]),
|
|
263
|
-
"after-body": E(() => [
|
|
263
|
+
"after-body": E(() => [e.aboutMode ? p("", !0) : (y(), f(ke, {
|
|
264
264
|
key: 0,
|
|
265
265
|
picture: q.value,
|
|
266
266
|
"contextual-description": ie.value,
|
|
@@ -300,13 +300,13 @@ var j = Object.defineProperty, M = (e, t) => {
|
|
|
300
300
|
_: 2
|
|
301
301
|
}, 1032, ["to", "class"])]))), 128))
|
|
302
302
|
])) : p("", !0)]),
|
|
303
|
-
after: E(({ next: n }) => [
|
|
303
|
+
after: E(({ next: n }) => [e.aboutMode && n ? (y(), m("div", ze, [i[0] ||= h("span", null, null, -1), _(C(A), {
|
|
304
304
|
to: C(s)(n),
|
|
305
305
|
class: "mwnf-dxa-theme__tour-link"
|
|
306
306
|
}, {
|
|
307
307
|
default: E(() => [g(S(C(P)("core.pagination.next")) + " " + S(Ve), 1)]),
|
|
308
308
|
_: 1
|
|
309
|
-
}, 8, ["to"])])) : p("", !0), _(
|
|
309
|
+
}, 8, ["to"])])) : p("", !0), _(t)]),
|
|
310
310
|
_: 1
|
|
311
311
|
}, 8, [
|
|
312
312
|
"spec",
|