@museumwnf/viewer-layout 3.61.0 → 3.63.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/dist/FeaturedRecord-Fe19w6_G.js +213 -0
- package/dist/LegacyItemSheet-Bmg8etGz.js +532 -0
- package/dist/{OnDisplayIn-DW4iC5BB.js → OnDisplayIn-BH3Bqope.js} +16 -9
- package/dist/{PageShell-CPtgzcxv.js → PageShell-CIGVv7sK.js} +144 -111
- package/dist/{PartnerMap-U-Hi2FBi.js → PartnerMap-DdyMLtgH.js} +5 -1
- package/dist/RecordView-Bgd5mm_e.js +384 -0
- package/dist/{SiteShell-qvsZO4Iz.js → SiteShell-UsZ_cpe9.js} +3 -2
- package/dist/Theme-Daezwp0p.js +391 -0
- package/dist/{TimelineEventList-1feZA5t7.js → TimelineEventList-CIkKxyQu.js} +122 -238
- package/dist/TimelineResultsView-BF3VoCs_.js +686 -0
- package/dist/components.js +1 -1
- package/dist/{content-BNS5U0Xv.js → content-hV5uyd-b.js} +2 -2
- package/dist/content.js +6 -6
- package/dist/data-CsMfGCkv.js +77 -0
- package/dist/data-DzrH9ikw.js +45 -0
- package/dist/dxa.js +2046 -1008
- package/dist/index.js +7 -7
- package/dist/standalone.js +3 -3
- package/dist/{themeSpecs-CsDpl4rR.js → themeSpecs-DIdmAEc3.js} +1 -1
- package/dist/viewer-layout.css +1 -1
- package/dist/views.js +755 -37
- package/package.json +1 -1
- package/src/dxa/testing.js +176 -120
- package/src/styles/dxa-exhibition.css +2289 -32
- package/src/styles/dxa-gallery.css +17 -2
- package/dist/FeaturedRecord-DaGLHyhD.js +0 -87
- package/dist/ItemDetailView-D7m2C1Mg.js +0 -310
- package/dist/RecordView-BE4mbj6G.js +0 -363
- package/dist/Theme-4RmyRY0x.js +0 -318
- package/dist/TimelineResultsView-CkH3NDqL.js +0 -1401
- package/dist/data-EKYeMQcC.js +0 -45
- package/dist/data-kqAkoQvf.js +0 -37
|
@@ -1,363 +0,0 @@
|
|
|
1
|
-
import { t as e } from "./GlossaryPopover-DbQKXhx9.js";
|
|
2
|
-
import { a as t, c as n, d as r, i, n as a, o as ee, r as te, s as ne } from "./PartnerMap-U-Hi2FBi.js";
|
|
3
|
-
import { Fragment as o, computed as s, createBlock as c, createCommentVNode as l, createElementBlock as u, createElementVNode as d, createSlots as re, createTextVNode as ie, createVNode as f, guardReactiveProps as p, mergeProps as ae, normalizeClass as oe, normalizeProps as m, openBlock as h, ref as g, renderList as _, renderSlot as v, toDisplayString as y, unref as b, useSlots as se, watch as x, withCtx as ce } from "vue";
|
|
4
|
-
import { useI18n as S } from "@museumwnf/viewer-core/i18n";
|
|
5
|
-
import { NotFoundView as le, byId as ue, citation as de, creditLine as fe, entityRef as pe, languageLabels as me, loadEntities as he, pictureCredits as ge, picturesInLanguage as _e, renderBlock as C, renderInline as w, renderPlain as T, sheetRows as E, sourceUrl as ve, useDataPackage as ye, useGlossaryPopup as be, useI18n as xe, useProjects as Se, useRecordSheet as Ce, useRelatedRecords as we } from "@museumwnf/viewer-core";
|
|
6
|
-
import { useRoute as Te } from "vue-router";
|
|
7
|
-
// src/content/ShortDescription.vue
|
|
8
|
-
var D = ["dir"], Ee = ["aria-expanded"], O = ["innerHTML"], De = {
|
|
9
|
-
__name: "ShortDescription",
|
|
10
|
-
props: {
|
|
11
|
-
html: {
|
|
12
|
-
type: String,
|
|
13
|
-
required: !0
|
|
14
|
-
},
|
|
15
|
-
dir: {
|
|
16
|
-
type: String,
|
|
17
|
-
default: void 0
|
|
18
|
-
}
|
|
19
|
-
},
|
|
20
|
-
setup(e) {
|
|
21
|
-
let t = e, { t: n } = S(), r = g(!1);
|
|
22
|
-
return x(() => t.html, () => {
|
|
23
|
-
r.value = !1;
|
|
24
|
-
}), (t, i) => (h(), u("div", {
|
|
25
|
-
class: "mwnf-sheet__short",
|
|
26
|
-
dir: e.dir
|
|
27
|
-
}, [d("button", {
|
|
28
|
-
type: "button",
|
|
29
|
-
class: "mwnf-sheet__toggle",
|
|
30
|
-
"aria-expanded": r.value ? "true" : "false",
|
|
31
|
-
onClick: i[0] ||= (e) => r.value = !r.value
|
|
32
|
-
}, y(r.value ? b(n)("record.action.hideShortDescription") : b(n)("record.action.viewShortDescription")), 9, Ee), r.value ? (h(), u("div", {
|
|
33
|
-
key: 0,
|
|
34
|
-
class: "mwnf-sheet__block",
|
|
35
|
-
innerHTML: e.html
|
|
36
|
-
}, null, 8, O)) : l("", !0)], 8, D));
|
|
37
|
-
}
|
|
38
|
-
};
|
|
39
|
-
// src/views/pictureLimit.js
|
|
40
|
-
function k(e, t, n) {
|
|
41
|
-
let r = typeof t == "function" ? t(n) : t;
|
|
42
|
-
return Number.isInteger(r) && r > 0 ? e.slice(0, r) : e;
|
|
43
|
-
}
|
|
44
|
-
// src/views/RecordView.vue
|
|
45
|
-
var Oe = ["dir", "innerHTML"], ke = { class: "mwnf-record__body" }, Ae = { class: "mwnf-record__main" }, je = {
|
|
46
|
-
key: 0,
|
|
47
|
-
class: "mwnf-record__media"
|
|
48
|
-
}, Me = {
|
|
49
|
-
key: 2,
|
|
50
|
-
class: "mwnf-record__status"
|
|
51
|
-
}, Ne = {
|
|
52
|
-
key: 0,
|
|
53
|
-
class: "mwnf-record__aside"
|
|
54
|
-
}, Pe = {
|
|
55
|
-
key: 2,
|
|
56
|
-
class: "mwnf-record__status"
|
|
57
|
-
}, A = {
|
|
58
|
-
__name: "RecordView",
|
|
59
|
-
props: {
|
|
60
|
-
spec: {
|
|
61
|
-
type: Object,
|
|
62
|
-
required: !0
|
|
63
|
-
},
|
|
64
|
-
id: {
|
|
65
|
-
type: String,
|
|
66
|
-
required: !0
|
|
67
|
-
},
|
|
68
|
-
entity: {
|
|
69
|
-
type: String,
|
|
70
|
-
default: ""
|
|
71
|
-
}
|
|
72
|
-
},
|
|
73
|
-
setup(g) {
|
|
74
|
-
let x = g, { t: S, tIn: D, locale: Ee } = xe(), O = ye(), A = Se(), Fe = se(), Ie = Te(), j = x.spec.entity ?? x.entity, M = s(() => x.spec), Le = pe(j), Re = ue(j), N = s(() => Re.value.get(x.id) ?? null), ze = s(() => Le.value !== null), P = x.spec.creditPeople ? x.spec.creditPeople.entity ?? "authors" : null;
|
|
75
|
-
P && he([P]).catch(() => {});
|
|
76
|
-
let F = P ? ue(P) : null, { language: I, languages: Be, dir: L, select: R, text: z, ready: B, terms: Ve, glossary: V, attribution: H } = Ce(N, {
|
|
77
|
-
entity: j,
|
|
78
|
-
translations: [...x.spec.translations ?? [], ...P ? [P] : []],
|
|
79
|
-
attribution: x.spec.attribution ?? []
|
|
80
|
-
}), U = s(() => me(Be.value)), { active: W, onClick: He, close: Ue } = be(Ve), We = s(() => W.value ? C(W.value.definition, { breaks: !0 }) : ""), Ge = (e, t) => O.tr(e, t, I.value, "en"), Ke = (e) => O.translations(e, I.value), G = s(() => ({
|
|
81
|
-
record: N.value,
|
|
82
|
-
text: z.value,
|
|
83
|
-
language: I.value,
|
|
84
|
-
languages: U.value,
|
|
85
|
-
select: R,
|
|
86
|
-
dir: L.value,
|
|
87
|
-
glossary: V.value,
|
|
88
|
-
ready: B.value,
|
|
89
|
-
attribution: H.value,
|
|
90
|
-
t: S,
|
|
91
|
-
tIn: (e) => D ? D(I.value, e) : S(e),
|
|
92
|
-
tr: Ge,
|
|
93
|
-
translations: Ke
|
|
94
|
-
})), K = (e) => M.value.labelsInRecordLanguage && D ? D(I.value, e) : S(e);
|
|
95
|
-
function qe(e) {
|
|
96
|
-
return ((typeof e == "function" ? e(G.value) : e) ?? []).map((e) => ({
|
|
97
|
-
...e,
|
|
98
|
-
label: e.label ? K(e.label) : ""
|
|
99
|
-
}));
|
|
100
|
-
}
|
|
101
|
-
let Je = s(() => N.value ? E(qe(M.value.fields), G.value) : []), Ye = s(() => N.value ? E(qe(M.value.sections).map((e) => ({
|
|
102
|
-
render: "block",
|
|
103
|
-
...e
|
|
104
|
-
})), G.value) : []), q = s(() => M.value.shortDescriptionAfter ?? "description"), Xe = s(() => !Je.value.some((e) => e.key === q.value) && Ye.value.some((e) => e.key === q.value)), Ze = s(() => M.value.shortDescription === !1 ? "" : M.value.shortDescription ?? "short_description"), J = s(() => {
|
|
105
|
-
let e = Ze.value ? z.value[Ze.value] : "";
|
|
106
|
-
return e ? { html: C(String(e), {
|
|
107
|
-
breaks: !0,
|
|
108
|
-
glossary: V.value
|
|
109
|
-
}) } : null;
|
|
110
|
-
}), Qe = s(() => {
|
|
111
|
-
if (!N.value) return "";
|
|
112
|
-
if (M.value.title) return M.value.title(G.value);
|
|
113
|
-
let e = z.value.name ?? N.value.internal_name ?? N.value.id;
|
|
114
|
-
return w(String(e), { glossary: V.value });
|
|
115
|
-
}), Y = s(() => N.value ? k($e(), M.value.pictureLimit, G.value) : []);
|
|
116
|
-
function $e() {
|
|
117
|
-
if (M.value.media) return M.value.media(N.value, G.value);
|
|
118
|
-
let e = T(String(z.value.name ?? N.value.internal_name ?? ""));
|
|
119
|
-
return _e(N.value.images, I.value).map((t) => ({
|
|
120
|
-
url: t.url,
|
|
121
|
-
alt: t.captions?.[I.value] ?? e,
|
|
122
|
-
caption: t.captions?.[I.value] ?? "",
|
|
123
|
-
...ge(t, I.value)
|
|
124
|
-
}));
|
|
125
|
-
}
|
|
126
|
-
let et = [
|
|
127
|
-
{
|
|
128
|
-
field: "author",
|
|
129
|
-
label: "sheet.field.preparedBy"
|
|
130
|
-
},
|
|
131
|
-
{
|
|
132
|
-
field: "copy_editor",
|
|
133
|
-
label: "sheet.field.copyeditedBy"
|
|
134
|
-
},
|
|
135
|
-
{
|
|
136
|
-
field: "translator",
|
|
137
|
-
label: "sheet.field.translationBy"
|
|
138
|
-
},
|
|
139
|
-
{
|
|
140
|
-
field: "translation_copy_editor",
|
|
141
|
-
label: "sheet.field.translationCopyeditedBy"
|
|
142
|
-
}
|
|
143
|
-
];
|
|
144
|
-
function tt(e) {
|
|
145
|
-
let t = M.value.creditNames ? z.value.credit_names?.[e] : null;
|
|
146
|
-
return t?.length ? fe(t) : z.value[e] ?? H.value[e] ?? "";
|
|
147
|
-
}
|
|
148
|
-
function nt(e) {
|
|
149
|
-
let t = F ? z.value.credit_ids?.[e] : null;
|
|
150
|
-
if (!t?.length) return null;
|
|
151
|
-
let n = Ke(P), r = t.map((e) => {
|
|
152
|
-
let t = F.value.get(e);
|
|
153
|
-
if (!t) return null;
|
|
154
|
-
let r = t.name ?? "";
|
|
155
|
-
return {
|
|
156
|
-
name: I.value === "ar" && t.originalname ? t.originalname : r,
|
|
157
|
-
heading: [t.firstname, t.lastname].filter(Boolean).join(" ") || r,
|
|
158
|
-
biography: n?.[e]?.curriculum ?? ""
|
|
159
|
-
};
|
|
160
|
-
});
|
|
161
|
-
return r.every(Boolean) ? r : null;
|
|
162
|
-
}
|
|
163
|
-
let rt = s(() => (M.value.credits ?? et).map(({ field: e, label: t }) => ({
|
|
164
|
-
label: K(t),
|
|
165
|
-
value: tt(e),
|
|
166
|
-
people: nt(e)
|
|
167
|
-
})).filter((e) => e.value)), it = s(() => String(N.value?.[M.value.workingNumber ?? "mwnf_reference"] ?? ""));
|
|
168
|
-
function at(e) {
|
|
169
|
-
if (e?.permalink !== !1) return typeof e?.permalink == "string" ? e.permalink : ve(Ie) ?? void 0;
|
|
170
|
-
}
|
|
171
|
-
let ot = s(() => {
|
|
172
|
-
let e = M.value.citation;
|
|
173
|
-
return !N.value || typeof e?.format != "function" ? "" : e.format(G.value, {
|
|
174
|
-
permalink: at(e),
|
|
175
|
-
year: (/* @__PURE__ */ new Date()).getFullYear()
|
|
176
|
-
});
|
|
177
|
-
}), X = s(() => {
|
|
178
|
-
let e = M.value.citation;
|
|
179
|
-
if (!N.value || e === !1 || typeof e?.format == "function") return "";
|
|
180
|
-
let t = typeof e?.project == "function" ? null : e?.project ?? N.value.project_id, n = typeof e?.project == "function" ? e.project(N.value, G.value) : A.label(t);
|
|
181
|
-
return de({
|
|
182
|
-
author: tt("author") || void 0,
|
|
183
|
-
name: z.value.name ?? N.value.internal_name ?? "",
|
|
184
|
-
project: n,
|
|
185
|
-
permalink: at(e),
|
|
186
|
-
inWord: S("record.citation.in")
|
|
187
|
-
});
|
|
188
|
-
}), Z = we(N, {
|
|
189
|
-
entity: j,
|
|
190
|
-
language: I
|
|
191
|
-
}), Q = s(() => M.value.related === !1 ? null : M.value.related ?? {}), $ = s(() => {
|
|
192
|
-
if (!Q.value) return [];
|
|
193
|
-
let e = Q.value.record ?? st;
|
|
194
|
-
return Z.value.inPackage.map((t) => e(t, G.value));
|
|
195
|
-
});
|
|
196
|
-
function st({ record: e, justification: t }) {
|
|
197
|
-
let n = Ge(j, e.id).name ?? e.internal_name ?? e.id;
|
|
198
|
-
return {
|
|
199
|
-
id: e.id,
|
|
200
|
-
image: e.images?.[0]?.url ?? "",
|
|
201
|
-
imageAlt: T(String(n)),
|
|
202
|
-
name: w(String(n)),
|
|
203
|
-
meta: t ? [t] : [],
|
|
204
|
-
badge: e.type ?? "",
|
|
205
|
-
to: {
|
|
206
|
-
name: M.value.route ?? (x.entity ? `${x.entity}-detail` : "item"),
|
|
207
|
-
params: { id: e.id }
|
|
208
|
-
}
|
|
209
|
-
};
|
|
210
|
-
}
|
|
211
|
-
let ct = /* @__PURE__ */ new Set([
|
|
212
|
-
"header",
|
|
213
|
-
"before-sheet",
|
|
214
|
-
"after-sheet",
|
|
215
|
-
"after-media",
|
|
216
|
-
"credits",
|
|
217
|
-
"aside",
|
|
218
|
-
"source",
|
|
219
|
-
"related",
|
|
220
|
-
"after",
|
|
221
|
-
"default"
|
|
222
|
-
]), lt = s(() => Object.keys(Fe).filter((e) => !ct.has(e)));
|
|
223
|
-
return (s, g) => ze.value && !N.value ? (h(), c(b(le), { key: 0 })) : N.value ? (h(), u("article", {
|
|
224
|
-
key: 1,
|
|
225
|
-
class: oe(["mwnf-record", { "mwnf-record--spaced": M.value.spaced }]),
|
|
226
|
-
onClick: g[0] ||= (...e) => b(He) && b(He)(...e)
|
|
227
|
-
}, [
|
|
228
|
-
v(s.$slots, "header", m(p(G.value)), () => [
|
|
229
|
-
M.value.back ? (h(), c(r, {
|
|
230
|
-
key: 0,
|
|
231
|
-
class: "mwnf-record__back",
|
|
232
|
-
to: M.value.back.to,
|
|
233
|
-
href: M.value.back.href
|
|
234
|
-
}, {
|
|
235
|
-
default: ce(() => [ie("← " + y(b(S)(M.value.back.label)), 1)]),
|
|
236
|
-
_: 1
|
|
237
|
-
}, 8, ["to", "href"])) : l("", !0),
|
|
238
|
-
f(n, {
|
|
239
|
-
languages: U.value,
|
|
240
|
-
language: b(I),
|
|
241
|
-
onSelect: b(R)
|
|
242
|
-
}, null, 8, [
|
|
243
|
-
"languages",
|
|
244
|
-
"language",
|
|
245
|
-
"onSelect"
|
|
246
|
-
]),
|
|
247
|
-
d("h1", {
|
|
248
|
-
class: "mwnf-record__title",
|
|
249
|
-
dir: b(L) || void 0,
|
|
250
|
-
innerHTML: Qe.value
|
|
251
|
-
}, null, 8, Oe)
|
|
252
|
-
]),
|
|
253
|
-
d("div", ke, [d("div", Ae, [
|
|
254
|
-
s.$slots["after-media"] ? (h(), u("div", je, [Y.value.length ? (h(), c(a, {
|
|
255
|
-
key: 0,
|
|
256
|
-
images: Y.value,
|
|
257
|
-
variant: M.value.mediaVariant ?? ""
|
|
258
|
-
}, null, 8, ["images", "variant"])) : l("", !0), v(s.$slots, "after-media", m(p(G.value)))])) : Y.value.length ? (h(), c(a, {
|
|
259
|
-
key: 1,
|
|
260
|
-
images: Y.value,
|
|
261
|
-
variant: M.value.mediaVariant ?? ""
|
|
262
|
-
}, null, 8, ["images", "variant"])) : l("", !0),
|
|
263
|
-
b(B) ? l("", !0) : (h(), u("p", Me, y(b(S)("core.status.loading")), 1)),
|
|
264
|
-
v(s.$slots, "before-sheet", m(p(G.value))),
|
|
265
|
-
f(ne, {
|
|
266
|
-
rows: Je.value,
|
|
267
|
-
layout: M.value.layout ?? "table",
|
|
268
|
-
dir: b(L),
|
|
269
|
-
"short-description": J.value,
|
|
270
|
-
"short-description-after": q.value,
|
|
271
|
-
"toggle-labels": M.value.shortDescriptionLabels ?? {}
|
|
272
|
-
}, re({ _: 2 }, [_(lt.value, (e) => ({
|
|
273
|
-
name: e,
|
|
274
|
-
fn: ce((t) => [v(s.$slots, e, m(p({
|
|
275
|
-
...t,
|
|
276
|
-
...G.value
|
|
277
|
-
})))])
|
|
278
|
-
}))]), 1032, [
|
|
279
|
-
"rows",
|
|
280
|
-
"layout",
|
|
281
|
-
"dir",
|
|
282
|
-
"short-description",
|
|
283
|
-
"short-description-after",
|
|
284
|
-
"toggle-labels"
|
|
285
|
-
]),
|
|
286
|
-
(h(!0), u(o, null, _(Ye.value, (e) => (h(), u(o, { key: e.key }, [
|
|
287
|
-
f(ee, {
|
|
288
|
-
heading: e.label,
|
|
289
|
-
html: e.html,
|
|
290
|
-
dir: b(L)
|
|
291
|
-
}, null, 8, [
|
|
292
|
-
"heading",
|
|
293
|
-
"html",
|
|
294
|
-
"dir"
|
|
295
|
-
]),
|
|
296
|
-
J.value && Xe.value && e.key === q.value ? (h(), c(De, {
|
|
297
|
-
key: 0,
|
|
298
|
-
html: J.value.html,
|
|
299
|
-
dir: b(L)
|
|
300
|
-
}, null, 8, ["html", "dir"])) : l("", !0),
|
|
301
|
-
v(s.$slots, `after-${e.key}`, ae({ ref_for: !0 }, G.value))
|
|
302
|
-
], 64))), 128)),
|
|
303
|
-
v(s.$slots, "after-sheet", m(p(G.value))),
|
|
304
|
-
v(s.$slots, "credits", m(p({
|
|
305
|
-
...G.value,
|
|
306
|
-
credits: rt.value,
|
|
307
|
-
workingNumber: it.value,
|
|
308
|
-
workingNumberLabel: K(M.value.workingNumberLabel ?? "sheet.field.workingNumber"),
|
|
309
|
-
citation: X.value,
|
|
310
|
-
citationHtml: ot.value
|
|
311
|
-
})), () => [f(t, {
|
|
312
|
-
credits: rt.value,
|
|
313
|
-
"working-number": it.value,
|
|
314
|
-
"working-number-label": K(M.value.workingNumberLabel ?? "sheet.field.workingNumber"),
|
|
315
|
-
citation: X.value,
|
|
316
|
-
"citation-html": ot.value,
|
|
317
|
-
"citation-heading": M.value.citation?.heading ? K(M.value.citation.heading) : ""
|
|
318
|
-
}, null, 8, [
|
|
319
|
-
"credits",
|
|
320
|
-
"working-number",
|
|
321
|
-
"working-number-label",
|
|
322
|
-
"citation",
|
|
323
|
-
"citation-html",
|
|
324
|
-
"citation-heading"
|
|
325
|
-
])]),
|
|
326
|
-
v(s.$slots, "source", m(p(G.value)), () => [M.value.sourceCredit === !1 ? l("", !0) : (h(), c(i, { key: 0 }))]),
|
|
327
|
-
v(s.$slots, "related", m(p({
|
|
328
|
-
...G.value,
|
|
329
|
-
records: $.value,
|
|
330
|
-
outside: b(Z).outside
|
|
331
|
-
})), () => [Q.value ? (h(), c(te, {
|
|
332
|
-
key: 0,
|
|
333
|
-
heading: b(S)(Q.value.heading ?? "record.related.items"),
|
|
334
|
-
records: $.value,
|
|
335
|
-
variant: Q.value.variant ?? "list",
|
|
336
|
-
"action-label": Q.value.actionLabel ? b(S)(Q.value.actionLabel) : ""
|
|
337
|
-
}, null, 8, [
|
|
338
|
-
"heading",
|
|
339
|
-
"records",
|
|
340
|
-
"variant",
|
|
341
|
-
"action-label"
|
|
342
|
-
])) : l("", !0)])
|
|
343
|
-
]), s.$slots.aside ? (h(), u("aside", Ne, [v(s.$slots, "aside", m(p({
|
|
344
|
-
...G.value,
|
|
345
|
-
records: $.value,
|
|
346
|
-
outside: b(Z).outside
|
|
347
|
-
})))])) : l("", !0)]),
|
|
348
|
-
v(s.$slots, "after", m(p(G.value))),
|
|
349
|
-
f(e, {
|
|
350
|
-
term: b(W),
|
|
351
|
-
html: We.value,
|
|
352
|
-
dir: b(L),
|
|
353
|
-
onClose: b(Ue)
|
|
354
|
-
}, null, 8, [
|
|
355
|
-
"term",
|
|
356
|
-
"html",
|
|
357
|
-
"dir",
|
|
358
|
-
"onClose"
|
|
359
|
-
])
|
|
360
|
-
], 2)) : (h(), u("p", Pe, y(b(S)("core.status.loading")), 1));
|
|
361
|
-
}
|
|
362
|
-
};
|
|
363
|
-
export { k as n, A as t };
|
package/dist/Theme-4RmyRY0x.js
DELETED
|
@@ -1,318 +0,0 @@
|
|
|
1
|
-
import { o as e } from "./TimelineResultsView-CkH3NDqL.js";
|
|
2
|
-
import { d as t, i as n } from "./PartnerMap-U-Hi2FBi.js";
|
|
3
|
-
import { A as r, F as i, h as a, m as o } from "./data-kqAkoQvf.js";
|
|
4
|
-
import { n as s, r as c, t as l } from "./themeSpecs-CsDpl4rR.js";
|
|
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
|
-
import { renderBlock as O, useI18n as k } from "@museumwnf/viewer-core";
|
|
7
|
-
import { RouterLink as A, useRoute as te, useRouter as ne } from "vue-router";
|
|
8
|
-
// \0rolldown/runtime.js
|
|
9
|
-
var j = Object.defineProperty, M = (e, t) => {
|
|
10
|
-
let n = {};
|
|
11
|
-
for (var r in e) j(n, r, {
|
|
12
|
-
get: e[r],
|
|
13
|
-
enumerable: !0
|
|
14
|
-
});
|
|
15
|
-
return t || j(n, Symbol.toStringTag, { value: "Module" }), n;
|
|
16
|
-
}, N = { class: "mwnf-picture-gallery" }, re = {
|
|
17
|
-
key: 0,
|
|
18
|
-
class: "mwnf-picture-gallery__selected"
|
|
19
|
-
}, P = { class: "mwnf-picture-gallery__image" }, F = ["src", "alt"], I = { class: "mwnf-picture-gallery__details" }, L = { class: "mwnf-picture-gallery__detail mwnf-picture-gallery__detail--title" }, R = { key: 0 }, z = ["innerHTML"], B = {
|
|
20
|
-
key: 0,
|
|
21
|
-
class: "mwnf-picture-gallery__label"
|
|
22
|
-
}, V = ["innerHTML"], H = {
|
|
23
|
-
key: 0,
|
|
24
|
-
class: "mwnf-picture-gallery__detail"
|
|
25
|
-
}, U = {
|
|
26
|
-
key: 2,
|
|
27
|
-
class: "mwnf-picture-gallery__unresolved"
|
|
28
|
-
}, W = {
|
|
29
|
-
key: 1,
|
|
30
|
-
class: "mwnf-picture-gallery__empty"
|
|
31
|
-
}, G = {
|
|
32
|
-
key: 2,
|
|
33
|
-
class: "mwnf-picture-gallery__strip"
|
|
34
|
-
}, K = { class: "mwnf-picture-gallery__thumbs" }, q = ["onClick"], J = ["src", "alt"], Y = { class: "mwnf-picture-gallery__thumb-text" }, X = { key: 0 }, Z = ["innerHTML"], Q = { key: 1 }, ie = {
|
|
35
|
-
key: 0,
|
|
36
|
-
class: "mwnf-picture-gallery__toggle"
|
|
37
|
-
}, ae = {
|
|
38
|
-
__name: "PictureGallery",
|
|
39
|
-
props: {
|
|
40
|
-
pictures: {
|
|
41
|
-
type: Array,
|
|
42
|
-
default: () => []
|
|
43
|
-
},
|
|
44
|
-
selectedId: {
|
|
45
|
-
type: [String, Number],
|
|
46
|
-
default: null
|
|
47
|
-
},
|
|
48
|
-
seeItemEntry: {
|
|
49
|
-
type: String,
|
|
50
|
-
default: "exhibition.theme.seeItemEntry"
|
|
51
|
-
},
|
|
52
|
-
unresolvedEntry: {
|
|
53
|
-
type: String,
|
|
54
|
-
default: "exhibition.theme.recordNotInSite"
|
|
55
|
-
},
|
|
56
|
-
emptyEntry: {
|
|
57
|
-
type: String,
|
|
58
|
-
default: "exhibition.theme.additionalContent"
|
|
59
|
-
},
|
|
60
|
-
addRelatedEntry: {
|
|
61
|
-
type: String,
|
|
62
|
-
default: "exhibition.theme.addRelatedWorks"
|
|
63
|
-
},
|
|
64
|
-
hideRelatedEntry: {
|
|
65
|
-
type: String,
|
|
66
|
-
default: "exhibition.theme.hideRelatedWorks"
|
|
67
|
-
}
|
|
68
|
-
},
|
|
69
|
-
emits: ["update:selectedId"],
|
|
70
|
-
setup(e, { emit: n }) {
|
|
71
|
-
let r = e, 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
|
-
T(() => r.pictures, () => {
|
|
73
|
-
c.value = !1;
|
|
74
|
-
});
|
|
75
|
-
let l = d(() => c.value ? r.pictures : r.pictures.filter((e) => !e.backRelated?.length));
|
|
76
|
-
function _(e) {
|
|
77
|
-
i("update:selectedId", e.id);
|
|
78
|
-
}
|
|
79
|
-
return (n, r) => (y(), m("div", N, [o.value ? (y(), m("div", re, [h("div", P, [h("img", {
|
|
80
|
-
src: o.value.image,
|
|
81
|
-
alt: o.value.imageAlt ?? ""
|
|
82
|
-
}, null, 8, F)]), h("div", I, [
|
|
83
|
-
h("div", L, [o.value.imageCaption ? (y(), m("span", R, S(o.value.imageCaption) + ", ", 1)) : p("", !0), h("span", { innerHTML: o.value.name }, null, 8, z)]),
|
|
84
|
-
(y(!0), m(u, null, x(o.value.fields ?? [], (e, t) => (y(), m("div", {
|
|
85
|
-
key: t,
|
|
86
|
-
class: "mwnf-picture-gallery__detail"
|
|
87
|
-
}, [e.label ? (y(), m("span", B, S(e.label), 1)) : p("", !0), h("span", { innerHTML: e.value }, null, 8, V)]))), 128)),
|
|
88
|
-
o.value.detail ? (y(), m("div", H, S(o.value.detail), 1)) : p("", !0),
|
|
89
|
-
o.value.to ? (y(), f(t, {
|
|
90
|
-
key: 1,
|
|
91
|
-
class: "mwnf-picture-gallery__link",
|
|
92
|
-
to: o.value.to
|
|
93
|
-
}, {
|
|
94
|
-
default: E(() => [g(S(C(a)(e.seeItemEntry)) + " →", 1)]),
|
|
95
|
-
_: 1
|
|
96
|
-
}, 8, ["to"])) : (y(), m("div", U, S(C(a)(e.unresolvedEntry)), 1))
|
|
97
|
-
])])) : (y(), m("div", W, S(C(a)(e.emptyEntry)), 1)), e.pictures.length ? (y(), m("div", G, [h("ul", K, [(y(!0), m(u, null, x(l.value, (t) => (y(), m("li", {
|
|
98
|
-
key: t.id,
|
|
99
|
-
class: v(["mwnf-picture-gallery__thumb", {
|
|
100
|
-
"mwnf-picture-gallery__thumb--active": t.id === e.selectedId,
|
|
101
|
-
"mwnf-picture-gallery__thumb--related": t.backRelated?.length
|
|
102
|
-
}])
|
|
103
|
-
}, [h("button", {
|
|
104
|
-
type: "button",
|
|
105
|
-
onClick: (e) => _(t)
|
|
106
|
-
}, [h("img", {
|
|
107
|
-
src: t.image,
|
|
108
|
-
alt: t.imageAlt ?? "",
|
|
109
|
-
loading: "lazy"
|
|
110
|
-
}, null, 8, J)], 8, q), h("div", Y, [
|
|
111
|
-
t.imageCaption ? (y(), m("span", X, S(t.imageCaption) + ", ", 1)) : p("", !0),
|
|
112
|
-
h("span", {
|
|
113
|
-
class: "mwnf-picture-gallery__thumb-name",
|
|
114
|
-
innerHTML: t.name
|
|
115
|
-
}, null, 8, Z),
|
|
116
|
-
t.detail ? (y(), m("span", Q, ", " + S(t.detail), 1)) : p("", !0)
|
|
117
|
-
])], 2))), 128))]), s.value ? (y(), m("label", ie, [D(h("input", {
|
|
118
|
-
"onUpdate:modelValue": r[0] ||= (e) => c.value = e,
|
|
119
|
-
type: "checkbox"
|
|
120
|
-
}, null, 512), [[w, c.value]]), h("span", null, S(c.value ? C(a)(e.hideRelatedEntry) : C(a)(e.addRelatedEntry)), 1)])) : p("", !0)])) : p("", !0)]));
|
|
121
|
-
}
|
|
122
|
-
}, $ = {
|
|
123
|
-
key: 0,
|
|
124
|
-
class: "mwnf-picture-narrative"
|
|
125
|
-
}, oe = ["innerHTML"], se = {
|
|
126
|
-
key: 1,
|
|
127
|
-
class: "mwnf-picture-narrative__related"
|
|
128
|
-
}, ce = { class: "mwnf-picture-narrative__heading" }, le = { class: "mwnf-picture-narrative__images" }, ue = { class: "mwnf-picture-narrative__image mwnf-picture-narrative__image--main" }, de = ["src", "alt"], fe = { class: "mwnf-picture-narrative__thumb-text" }, pe = ["innerHTML"], me = { key: 0 }, he = ["onClick"], ge = ["src", "alt"], _e = { class: "mwnf-picture-narrative__thumb-text" }, ve = ["innerHTML"], ye = { key: 0 }, be = {
|
|
129
|
-
key: 0,
|
|
130
|
-
class: "mwnf-picture-narrative__relation"
|
|
131
|
-
}, xe = {
|
|
132
|
-
key: 2,
|
|
133
|
-
class: "mwnf-picture-narrative__related"
|
|
134
|
-
}, Se = { class: "mwnf-picture-narrative__heading" }, Ce = { class: "mwnf-picture-narrative__text mwnf-picture-narrative__text--reciprocal" }, we = { class: "mwnf-picture-narrative__image" }, Te = ["src", "alt"], Ee = { class: "mwnf-picture-narrative__thumb-text" }, De = ["innerHTML"], Oe = { key: 0 }, ke = {
|
|
135
|
-
__name: "PictureNarrative",
|
|
136
|
-
props: {
|
|
137
|
-
picture: {
|
|
138
|
-
type: Object,
|
|
139
|
-
default: null
|
|
140
|
-
},
|
|
141
|
-
contextualDescription: {
|
|
142
|
-
type: String,
|
|
143
|
-
default: ""
|
|
144
|
-
},
|
|
145
|
-
relatedHeadingEntry: {
|
|
146
|
-
type: String,
|
|
147
|
-
default: "exhibition.related.items"
|
|
148
|
-
},
|
|
149
|
-
reciprocalFallbackEntry: {
|
|
150
|
-
type: String,
|
|
151
|
-
default: "exhibition.related.reciprocal"
|
|
152
|
-
}
|
|
153
|
-
},
|
|
154
|
-
emits: ["select"],
|
|
155
|
-
setup(e, { emit: t }) {
|
|
156
|
-
let n = e, r = t, { t: i } = k(), a = d(() => n.contextualDescription ? O(n.contextualDescription, { breaks: !0 }) : ""), o = d(() => n.picture?.related ?? []), s = d(() => n.picture?.backRelated?.[0] ?? null);
|
|
157
|
-
function c(e) {
|
|
158
|
-
r("select", e.id);
|
|
159
|
-
}
|
|
160
|
-
return (t, n) => e.picture ? (y(), m("div", $, [
|
|
161
|
-
a.value ? (y(), m("div", {
|
|
162
|
-
key: 0,
|
|
163
|
-
class: "mwnf-picture-narrative__text mwnf-sheet__block",
|
|
164
|
-
innerHTML: a.value
|
|
165
|
-
}, null, 8, oe)) : p("", !0),
|
|
166
|
-
o.value.length ? (y(), m("div", se, [h("div", ce, S(C(i)(e.relatedHeadingEntry)), 1), h("div", le, [h("div", ue, [h("img", {
|
|
167
|
-
src: e.picture.image,
|
|
168
|
-
alt: e.picture.imageAlt ?? ""
|
|
169
|
-
}, null, 8, de), h("div", fe, [h("span", { innerHTML: e.picture.name }, null, 8, pe), e.picture.detail ? (y(), m("span", me, ", " + S(e.picture.detail), 1)) : p("", !0)])]), (y(!0), m(u, null, x(o.value, (e) => (y(), m("div", {
|
|
170
|
-
key: e.picture.id,
|
|
171
|
-
class: "mwnf-picture-narrative__image"
|
|
172
|
-
}, [
|
|
173
|
-
h("button", {
|
|
174
|
-
type: "button",
|
|
175
|
-
onClick: (t) => c(e.picture)
|
|
176
|
-
}, [h("img", {
|
|
177
|
-
src: e.picture.image,
|
|
178
|
-
alt: e.picture.imageAlt ?? ""
|
|
179
|
-
}, null, 8, ge)], 8, he),
|
|
180
|
-
h("div", _e, [h("span", { innerHTML: e.picture.name }, null, 8, ve), e.picture.detail ? (y(), m("span", ye, ", " + S(e.picture.detail), 1)) : p("", !0)]),
|
|
181
|
-
e.text ? (y(), m("div", be, S(e.text), 1)) : p("", !0)
|
|
182
|
-
]))), 128))])])) : p("", !0),
|
|
183
|
-
s.value ? (y(), m("div", xe, [
|
|
184
|
-
h("div", Se, S(C(i)(e.relatedHeadingEntry)), 1),
|
|
185
|
-
h("p", Ce, S(s.value.reciprocalText || C(i)(e.reciprocalFallbackEntry)), 1),
|
|
186
|
-
h("div", we, [h("button", {
|
|
187
|
-
type: "button",
|
|
188
|
-
onClick: n[0] ||= (e) => c(s.value.picture)
|
|
189
|
-
}, [h("img", {
|
|
190
|
-
src: s.value.picture.image,
|
|
191
|
-
alt: s.value.picture.imageAlt ?? ""
|
|
192
|
-
}, null, 8, Te)]), h("div", Ee, [h("span", { innerHTML: s.value.picture.name }, null, 8, De), s.value.picture.detail ? (y(), m("span", Oe, ", " + S(s.value.picture.detail), 1)) : p("", !0)])])
|
|
193
|
-
])) : p("", !0)
|
|
194
|
-
])) : p("", !0);
|
|
195
|
-
}
|
|
196
|
-
}, Ae = /* @__PURE__ */ M({ default: () => He }), je = { class: "mwnf-dxa-theme__heading" }, Me = {
|
|
197
|
-
key: 0,
|
|
198
|
-
class: "mwnf-dxa-theme__numeral"
|
|
199
|
-
}, Ne = { class: "mwnf-dxa-theme__subheading" }, Pe = { class: "mwnf-dxa-theme__tour" }, Fe = { key: 1 }, Ie = {
|
|
200
|
-
key: 0,
|
|
201
|
-
class: "mwnf-dxa-theme__subthemes"
|
|
202
|
-
}, Le = { class: "mwnf-dxa-theme__subthemes-label" }, Re = { class: "mwnf-dxa-theme__subtheme" }, ze = {
|
|
203
|
-
key: 0,
|
|
204
|
-
class: "mwnf-dxa-theme__tour"
|
|
205
|
-
}, Be = {
|
|
206
|
-
key: 1,
|
|
207
|
-
class: "mwnf-loader"
|
|
208
|
-
}, Ve = "→", He = {
|
|
209
|
-
__name: "Theme",
|
|
210
|
-
props: { aboutMode: {
|
|
211
|
-
type: Boolean,
|
|
212
|
-
default: !1
|
|
213
|
-
} },
|
|
214
|
-
setup(t) {
|
|
215
|
-
let w = t, { 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
|
-
let e = I.params.subtheme;
|
|
217
|
-
if (w.aboutMode || !e || e === "overview") return null;
|
|
218
|
-
let t = Number(e);
|
|
219
|
-
return Number.isInteger(t) && t >= 1 ? t : null;
|
|
220
|
-
}), B = d(() => z.value === null ? null : (R.value?.sub_themes ?? [])[z.value - 1] ?? null), V = d(() => B.value ?? R.value), H = d(() => w.aboutMode ? l : c), U = re(V), W = b(null);
|
|
221
|
-
function G() {
|
|
222
|
-
let e = Number(I.params.image);
|
|
223
|
-
return (U.value.find((t) => t.displayOrder === e) ?? U.value[0])?.id ?? null;
|
|
224
|
-
}
|
|
225
|
-
function K() {
|
|
226
|
-
W.value = G();
|
|
227
|
-
}
|
|
228
|
-
ee(K), T(() => [
|
|
229
|
-
I.params.id,
|
|
230
|
-
I.params.subtheme,
|
|
231
|
-
w.aboutMode
|
|
232
|
-
], K);
|
|
233
|
-
let q = d(() => U.value.find((e) => e.id === W.value) ?? null);
|
|
234
|
-
function J(e) {
|
|
235
|
-
if (W.value = e, w.aboutMode) return;
|
|
236
|
-
let t = U.value.find((t) => t.id === e);
|
|
237
|
-
t && L.replace({
|
|
238
|
-
name: "theme",
|
|
239
|
-
params: {
|
|
240
|
-
id: I.params.id,
|
|
241
|
-
subtheme: I.params.subtheme ?? "overview",
|
|
242
|
-
image: String(t.displayOrder)
|
|
243
|
-
}
|
|
244
|
-
});
|
|
245
|
-
}
|
|
246
|
-
let Y = d(() => N(R.value, F.value).title ?? R.value?.internal_name ?? ""), X = d(() => w.aboutMode ? a(F.value) : Y.value), Z = d(() => w.aboutMode ? o(F.value) : B.value ? N(B.value, F.value).title ?? B.value.internal_name ?? "" : P("exhibition.theme.overview")), Q = d(() => j(O(R.value)?.display_order ?? 1)), ie = d(() => !V.value?.id || !q.value?.id ? "" : i("themes", `${V.value.id}/${q.value.id}`, F.value).contextual_description ?? ""), $ = d(() => (R.value?.sub_themes ?? []).map((e, t) => ({
|
|
247
|
-
index: t + 1,
|
|
248
|
-
title: N(e, F.value).title ?? e.internal_name ?? "",
|
|
249
|
-
to: s(e)
|
|
250
|
-
}))), oe = d(() => R.value ? s(R.value) : null);
|
|
251
|
-
return (r, i) => V.value ? (y(), f(e, {
|
|
252
|
-
key: 0,
|
|
253
|
-
spec: H.value,
|
|
254
|
-
id: V.value.id,
|
|
255
|
-
class: v(["mwnf-dxa-theme", { "mwnf-dxa-theme--about": t.aboutMode }])
|
|
256
|
-
}, {
|
|
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
|
-
panel: E(() => [_(ae, {
|
|
259
|
-
pictures: C(U),
|
|
260
|
-
"selected-id": W.value,
|
|
261
|
-
"onUpdate:selectedId": J
|
|
262
|
-
}, null, 8, ["pictures", "selected-id"])]),
|
|
263
|
-
"after-body": E(() => [t.aboutMode ? p("", !0) : (y(), f(ke, {
|
|
264
|
-
key: 0,
|
|
265
|
-
picture: q.value,
|
|
266
|
-
"contextual-description": ie.value,
|
|
267
|
-
onSelect: J
|
|
268
|
-
}, null, 8, ["picture", "contextual-description"]))]),
|
|
269
|
-
navigation: E(({ previous: e, next: t }) => [h("div", Pe, [e ? (y(), f(C(A), {
|
|
270
|
-
key: 0,
|
|
271
|
-
to: C(s)(e),
|
|
272
|
-
class: "mwnf-dxa-theme__tour-link"
|
|
273
|
-
}, {
|
|
274
|
-
default: E(() => [g("← " + S(C(P)("core.pagination.previous")), 1)]),
|
|
275
|
-
_: 1
|
|
276
|
-
}, 8, ["to"])) : (y(), m("span", Fe)), t ? (y(), f(C(A), {
|
|
277
|
-
key: 2,
|
|
278
|
-
to: C(s)(t),
|
|
279
|
-
class: "mwnf-dxa-theme__tour-link"
|
|
280
|
-
}, {
|
|
281
|
-
default: E(() => [g(S(C(P)("core.pagination.next")) + " " + S(Ve), 1)]),
|
|
282
|
-
_: 1
|
|
283
|
-
}, 8, ["to"])) : p("", !0)]), $.value.length ? (y(), m("div", Ie, [
|
|
284
|
-
h("div", Le, S(C(P)("exhibition.theme.inThisTheme")), 1),
|
|
285
|
-
h("div", Re, [_(C(A), {
|
|
286
|
-
to: oe.value,
|
|
287
|
-
class: v({ "mwnf-dxa-theme__subtheme--current": z.value === null })
|
|
288
|
-
}, {
|
|
289
|
-
default: E(() => [g(S(C(P)("exhibition.theme.overview")), 1)]),
|
|
290
|
-
_: 1
|
|
291
|
-
}, 8, ["to", "class"])]),
|
|
292
|
-
(y(!0), m(u, null, x($.value, (e) => (y(), m("div", {
|
|
293
|
-
key: e.index,
|
|
294
|
-
class: "mwnf-dxa-theme__subtheme"
|
|
295
|
-
}, [_(C(A), {
|
|
296
|
-
to: e.to,
|
|
297
|
-
class: v({ "mwnf-dxa-theme__subtheme--current": z.value === e.index })
|
|
298
|
-
}, {
|
|
299
|
-
default: E(() => [g(S(e.index) + ". " + S(e.title), 1)]),
|
|
300
|
-
_: 2
|
|
301
|
-
}, 1032, ["to", "class"])]))), 128))
|
|
302
|
-
])) : p("", !0)]),
|
|
303
|
-
after: E(({ next: e }) => [t.aboutMode && e ? (y(), m("div", ze, [i[0] ||= h("span", null, null, -1), _(C(A), {
|
|
304
|
-
to: C(s)(e),
|
|
305
|
-
class: "mwnf-dxa-theme__tour-link"
|
|
306
|
-
}, {
|
|
307
|
-
default: E(() => [g(S(C(P)("core.pagination.next")) + " " + S(Ve), 1)]),
|
|
308
|
-
_: 1
|
|
309
|
-
}, 8, ["to"])])) : p("", !0), _(n)]),
|
|
310
|
-
_: 1
|
|
311
|
-
}, 8, [
|
|
312
|
-
"spec",
|
|
313
|
-
"id",
|
|
314
|
-
"class"
|
|
315
|
-
])) : (y(), m("div", Be, S(C(P)("exhibition.theme.notInExhibition")), 1));
|
|
316
|
-
}
|
|
317
|
-
};
|
|
318
|
-
export { M as a, ae as i, He as n, ke as r, Ae as t };
|