@dso-toolkit/core 47.0.1 → 48.0.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/cjs/dso-accordion-section.cjs.entry.js +1447 -58
- package/dist/cjs/dso-autosuggest.cjs.entry.js +57 -47
- package/dist/cjs/dso-date-picker.cjs.entry.js +3 -2
- package/dist/cjs/dso-dropdown-menu.cjs.entry.js +2 -2
- package/dist/cjs/dso-helpcenter-panel.cjs.entry.js +1 -1
- package/dist/cjs/dso-image-overlay.cjs.entry.js +1 -1
- package/dist/cjs/dso-info_2.cjs.entry.js +2 -2
- package/dist/cjs/dso-label.cjs.entry.js +2 -2
- package/dist/cjs/dso-modal.cjs.entry.js +4 -7
- package/dist/cjs/dso-ozon-content.cjs.entry.js +3 -3
- package/dist/cjs/dso-table.cjs.entry.js +3 -5
- package/dist/cjs/dso-toggletip.cjs.entry.js +1 -1
- package/dist/cjs/dso-toolkit.cjs.js +2 -2
- package/dist/cjs/dso-tooltip.cjs.entry.js +13 -21
- package/dist/cjs/dso-viewer-grid.cjs.entry.js +8 -3
- package/dist/cjs/{focus-trap.esm-d83fd673.js → focus-trap.esm-c501d382.js} +82 -155
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/collection/collection-manifest.json +8 -8
- package/dist/collection/components/accordion/components/accordion-section.css +27 -4
- package/dist/collection/components/accordion/components/accordion-section.interfaces.js +6 -0
- package/dist/collection/components/accordion/components/accordion-section.js +91 -59
- package/dist/collection/components/accordion/components/handles/element.handle.js +7 -0
- package/dist/collection/components/accordion/components/handles/heading.handle.js +14 -0
- package/dist/collection/components/accordion/components/handles/icon.handle.js +13 -0
- package/dist/collection/components/accordion/components/handles/index.js +4 -0
- package/dist/collection/components/accordion/components/handles/state-icon.handle.js +15 -0
- package/dist/collection/components/autosuggest/autosuggest.interfaces.js +1 -0
- package/dist/collection/components/autosuggest/autosuggest.js +61 -49
- package/dist/collection/components/banner/banner.js +1 -1
- package/dist/collection/components/card-container/card-container.js +1 -1
- package/dist/collection/components/date-picker/date-picker.interfaces.js +1 -0
- package/dist/collection/components/date-picker/date-picker.js +19 -11
- package/dist/collection/components/dropdown-menu/dropdown-menu.js +2 -2
- package/dist/collection/components/header/header.js +2 -6
- package/dist/collection/components/info-button/info-button.interfaces.js +1 -0
- package/dist/collection/components/info-button/info-button.js +2 -1
- package/dist/collection/components/label/label.js +2 -2
- package/dist/collection/components/modal/modal.css +103 -75
- package/dist/collection/components/modal/modal.interfaces.js +1 -0
- package/dist/collection/components/modal/modal.js +5 -7
- package/dist/collection/components/ozon-content/nodes/noot.node.js +1 -1
- package/dist/collection/components/ozon-content/nodes/table.node/table.node.js +1 -1
- package/dist/collection/components/progress-indicator/progress-indicator.js +1 -1
- package/dist/collection/components/selectable/selectable.css +18 -1
- package/dist/collection/components/selectable/selectable.interfaces.js +1 -0
- package/dist/collection/components/selectable/selectable.js +3 -2
- package/dist/collection/components/table/table.css +49 -16
- package/dist/collection/components/table/table.js +2 -4
- package/dist/collection/components/toggletip/toggletip.js +1 -1
- package/dist/collection/components/tooltip/tooltip.js +13 -42
- package/dist/collection/components/tree-view/tree-view.js +8 -2
- package/dist/collection/components/viewer-grid/viewer-grid.interfaces.js +1 -0
- package/dist/collection/components/viewer-grid/viewer-grid.js +19 -11
- package/dist/collection/index.js +13 -0
- package/dist/components/clsx.m.js +3 -0
- package/dist/components/create-identifier.js +15 -0
- package/dist/components/dropdown-menu.js +151 -0
- package/dist/components/dso-accordion-section.d.ts +11 -0
- package/dist/components/dso-accordion-section.js +1535 -0
- package/dist/components/dso-accordion.d.ts +11 -0
- package/dist/components/dso-accordion.js +316 -0
- package/dist/components/dso-alert.d.ts +11 -0
- package/dist/components/dso-alert.js +55 -0
- package/dist/components/dso-attachments-counter.d.ts +11 -0
- package/dist/components/dso-attachments-counter.js +42 -0
- package/dist/components/dso-autosuggest.d.ts +11 -0
- package/dist/components/dso-autosuggest.js +309 -0
- package/dist/components/dso-badge.d.ts +11 -0
- package/dist/components/dso-badge.js +37 -0
- package/dist/components/dso-banner.d.ts +11 -0
- package/dist/components/dso-banner.js +37 -0
- package/dist/components/dso-card-container.d.ts +11 -0
- package/dist/components/dso-card-container.js +36 -0
- package/dist/components/dso-card.d.ts +11 -0
- package/dist/components/dso-card.js +66 -0
- package/dist/components/dso-date-picker.d.ts +11 -0
- package/dist/components/dso-date-picker.js +682 -0
- package/dist/components/dso-dropdown-menu.d.ts +11 -0
- package/dist/components/dso-dropdown-menu.js +6 -0
- package/dist/components/dso-header.d.ts +11 -0
- package/dist/components/dso-header.js +159 -0
- package/dist/components/dso-helpcenter-panel.d.ts +11 -0
- package/dist/components/dso-helpcenter-panel.js +127 -0
- package/dist/components/dso-highlight-box.d.ts +11 -0
- package/dist/components/dso-highlight-box.js +55 -0
- package/dist/components/dso-icon.d.ts +11 -0
- package/dist/components/dso-icon.js +6 -0
- package/dist/components/dso-image-overlay.d.ts +11 -0
- package/dist/components/dso-image-overlay.js +129 -0
- package/dist/components/dso-info-button.d.ts +11 -0
- package/dist/components/dso-info-button.js +6 -0
- package/dist/components/dso-info.d.ts +11 -0
- package/dist/components/dso-info.js +6 -0
- package/dist/components/dso-label.d.ts +11 -0
- package/dist/components/dso-label.js +156 -0
- package/dist/components/dso-map-base-layers.d.ts +11 -0
- package/dist/components/dso-map-base-layers.js +80 -0
- package/dist/components/dso-map-controls.d.ts +11 -0
- package/dist/components/dso-map-controls.js +86 -0
- package/dist/components/dso-map-overlays.d.ts +11 -0
- package/dist/components/dso-map-overlays.js +81 -0
- package/dist/components/dso-modal.d.ts +11 -0
- package/dist/components/dso-modal.js +85 -0
- package/dist/components/dso-ozon-content.d.ts +11 -0
- package/dist/components/dso-ozon-content.js +507 -0
- package/dist/components/dso-pagination.d.ts +11 -0
- package/dist/components/dso-pagination.js +159 -0
- package/dist/components/dso-progress-bar.d.ts +11 -0
- package/dist/components/dso-progress-bar.js +42 -0
- package/dist/components/dso-progress-indicator.d.ts +11 -0
- package/dist/components/dso-progress-indicator.js +6 -0
- package/dist/components/dso-responsive-element.d.ts +11 -0
- package/dist/components/dso-responsive-element.js +6 -0
- package/dist/components/dso-selectable.d.ts +11 -0
- package/dist/components/dso-selectable.js +6 -0
- package/dist/components/dso-table.d.ts +11 -0
- package/dist/components/dso-table.js +111 -0
- package/dist/components/dso-toggletip.d.ts +11 -0
- package/dist/components/dso-toggletip.js +90 -0
- package/dist/components/dso-tooltip.d.ts +11 -0
- package/dist/components/dso-tooltip.js +6 -0
- package/dist/components/dso-tree-view.d.ts +11 -0
- package/dist/components/dso-tree-view.js +227 -0
- package/dist/components/dso-viewer-grid.d.ts +11 -0
- package/dist/components/dso-viewer-grid.js +171 -0
- package/dist/components/focus-trap.esm.js +688 -0
- package/dist/components/icon.js +663 -0
- package/dist/components/index.d.ts +55 -0
- package/dist/components/index.esm.js +458 -0
- package/dist/components/index.js +35 -0
- package/dist/components/index2.js +70 -0
- package/dist/components/info-button.js +56 -0
- package/dist/components/info.js +42 -0
- package/dist/components/is-modified-event.js +4 -0
- package/dist/components/progress-indicator.js +44 -0
- package/dist/components/responsive-element.js +67 -0
- package/dist/components/selectable.js +108 -0
- package/dist/components/tooltip.js +2047 -0
- package/dist/components/v4.js +66 -0
- package/dist/dso-toolkit/dso-toolkit.esm.js +1 -1
- package/dist/dso-toolkit/p-04ffcc93.entry.js +1 -0
- package/dist/dso-toolkit/{p-e0a37d82.entry.js → p-06b4f78d.entry.js} +1 -1
- package/dist/dso-toolkit/{p-2b83a825.entry.js → p-35687d62.entry.js} +1 -1
- package/dist/dso-toolkit/p-52bc72d0.entry.js +1 -0
- package/dist/dso-toolkit/p-57ceabab.js +5 -0
- package/dist/dso-toolkit/p-655eff47.entry.js +1 -0
- package/dist/dso-toolkit/p-672c8323.entry.js +1 -0
- package/dist/dso-toolkit/p-7f8be9bc.entry.js +1 -0
- package/dist/dso-toolkit/p-80575700.entry.js +1 -0
- package/dist/dso-toolkit/p-8e9f6355.entry.js +1 -0
- package/dist/dso-toolkit/p-a8cb2eae.entry.js +1 -0
- package/dist/dso-toolkit/p-d31805a9.entry.js +1 -0
- package/dist/dso-toolkit/{p-dcc74039.entry.js → p-d7b2adc3.entry.js} +1 -1
- package/dist/dso-toolkit/{p-800e1267.entry.js → p-daee3252.entry.js} +1 -1
- package/dist/dso-toolkit/p-ec5412aa.entry.js +1 -0
- package/dist/esm/dso-accordion-section.entry.js +1448 -59
- package/dist/esm/dso-autosuggest.entry.js +57 -47
- package/dist/esm/dso-date-picker.entry.js +3 -2
- package/dist/esm/dso-dropdown-menu.entry.js +2 -2
- package/dist/esm/dso-helpcenter-panel.entry.js +1 -1
- package/dist/esm/dso-image-overlay.entry.js +1 -1
- package/dist/esm/dso-info_2.entry.js +2 -2
- package/dist/esm/dso-label.entry.js +2 -2
- package/dist/esm/dso-modal.entry.js +5 -8
- package/dist/esm/dso-ozon-content.entry.js +3 -3
- package/dist/esm/dso-table.entry.js +3 -5
- package/dist/esm/dso-toggletip.entry.js +1 -1
- package/dist/esm/dso-toolkit.js +2 -2
- package/dist/esm/dso-tooltip.entry.js +13 -21
- package/dist/esm/dso-viewer-grid.entry.js +8 -3
- package/dist/esm/{focus-trap.esm-33203b60.js → focus-trap.esm-94794d92.js} +82 -155
- package/dist/esm/loader.js +2 -2
- package/dist/types/components/accordion/accordion.interfaces.d.ts +0 -2
- package/dist/types/components/accordion/components/accordion-section.d.ts +10 -1
- package/dist/types/components/accordion/components/accordion-section.interfaces.d.ts +3 -0
- package/dist/types/components/accordion/components/handles/element.handle.d.ts +6 -0
- package/dist/types/components/accordion/components/handles/heading.handle.d.ts +5 -0
- package/dist/types/components/accordion/components/handles/icon.handle.d.ts +7 -0
- package/dist/types/components/accordion/components/handles/index.d.ts +4 -0
- package/dist/types/components/accordion/components/handles/state-icon.handle.d.ts +5 -0
- package/dist/types/components/autosuggest/autosuggest.d.ts +2 -15
- package/dist/types/components/autosuggest/autosuggest.interfaces.d.ts +14 -0
- package/dist/types/components/date-picker/date-picker.d.ts +2 -15
- package/dist/types/components/date-picker/date-picker.interfaces.d.ts +14 -0
- package/dist/types/components/dropdown-menu/dropdown-menu.d.ts +1 -1
- package/dist/types/components/header/header.d.ts +2 -2
- package/dist/types/components/header/header.interfaces.d.ts +1 -0
- package/dist/types/components/info-button/info-button.d.ts +1 -4
- package/dist/types/components/info-button/info-button.interfaces.d.ts +4 -0
- package/dist/types/components/map-overlays/map-overlays.d.ts +1 -1
- package/dist/types/components/modal/modal.d.ts +2 -4
- package/dist/types/components/modal/modal.interfaces.d.ts +3 -0
- package/dist/types/components/selectable/selectable.d.ts +1 -2
- package/dist/types/components/selectable/selectable.interfaces.d.ts +2 -0
- package/dist/types/components/table/table.d.ts +1 -1
- package/dist/types/components/tooltip/tooltip.d.ts +0 -8
- package/dist/types/components/tree-view/tree-view.d.ts +2 -2
- package/dist/types/components/viewer-grid/viewer-grid.d.ts +5 -16
- package/dist/types/components/viewer-grid/viewer-grid.interfaces.d.ts +15 -0
- package/dist/types/components.d.ts +20 -26
- package/dist/types/index.d.ts +13 -0
- package/package.json +8 -8
- package/dist/custom-elements/index.d.ts +0 -243
- package/dist/custom-elements/index.js +0 -7555
- package/dist/dso-toolkit/p-0917f18a.entry.js +0 -1
- package/dist/dso-toolkit/p-0c8cd0d8.entry.js +0 -1
- package/dist/dso-toolkit/p-203fc66c.entry.js +0 -1
- package/dist/dso-toolkit/p-3ab4441a.entry.js +0 -1
- package/dist/dso-toolkit/p-44c0bb3e.entry.js +0 -1
- package/dist/dso-toolkit/p-89d262b7.js +0 -5
- package/dist/dso-toolkit/p-9aa3fa9d.entry.js +0 -1
- package/dist/dso-toolkit/p-ba253bcd.entry.js +0 -1
- package/dist/dso-toolkit/p-e43e39cf.entry.js +0 -1
- package/dist/dso-toolkit/p-e8b22546.entry.js +0 -1
- package/dist/dso-toolkit/p-f93b7c7a.entry.js +0 -1
|
@@ -0,0 +1,507 @@
|
|
|
1
|
+
import { h, Fragment, proxyCustomElement, HTMLElement, createEvent, Host } from '@stencil/core/internal/client';
|
|
2
|
+
import { i as isTabbable } from './index.esm.js';
|
|
3
|
+
|
|
4
|
+
function getNodeName(node) {
|
|
5
|
+
if (node instanceof Element) {
|
|
6
|
+
return node.localName;
|
|
7
|
+
}
|
|
8
|
+
if (node.nodeName.includes(":")) {
|
|
9
|
+
return node.nodeName.substring(node.nodeName.indexOf(":") + 1);
|
|
10
|
+
}
|
|
11
|
+
return node.nodeName;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
class OzonContentAlNode {
|
|
15
|
+
constructor() {
|
|
16
|
+
this.name = "Al";
|
|
17
|
+
}
|
|
18
|
+
render(node, { mapNodeToJsx, path }) {
|
|
19
|
+
const nestedAl = path.some((node) => {
|
|
20
|
+
const nodeName = getNodeName(node);
|
|
21
|
+
return nodeName === "Al" || nodeName === "Opschrift";
|
|
22
|
+
});
|
|
23
|
+
const content = mapNodeToJsx(node.childNodes);
|
|
24
|
+
return nestedAl ? h("span", { role: "paragraph" }, content) : h("p", null, content);
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
class OzonContentDocumentNode {
|
|
29
|
+
constructor() {
|
|
30
|
+
this.name = "#document";
|
|
31
|
+
}
|
|
32
|
+
render(node, { mapNodeToJsx }) {
|
|
33
|
+
return h(Fragment, null, mapNodeToJsx(node.childNodes));
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
class OzonContentExtRefNode {
|
|
38
|
+
constructor() {
|
|
39
|
+
this.name = ["ExtRef", "ExtIoRef"];
|
|
40
|
+
}
|
|
41
|
+
render(node, { mapNodeToJsx }) {
|
|
42
|
+
const href = node.tagName === "ExtIoRef" ? node.getAttribute("href") : node.getAttribute("ref");
|
|
43
|
+
return (h("a", { target: "_blank", rel: "noopener noreferrer", href: href !== null && href !== void 0 ? href : undefined },
|
|
44
|
+
h("span", { class: "sr-only" }, "opent in nieuw venster"),
|
|
45
|
+
mapNodeToJsx(node.childNodes)));
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
const Bijschrift = ({ bijschrift, bron, mapNodeToJsx }) => {
|
|
50
|
+
return (h("span", { class: "figuur-bijschrift" },
|
|
51
|
+
bijschrift && bijschrift.inhoud && mapNodeToJsx(bijschrift.inhoud),
|
|
52
|
+
bron && `${bijschrift ? " " : ""}(bron: ${mapNodeToJsx(bron)})`));
|
|
53
|
+
};
|
|
54
|
+
class OzonContentFiguurNode {
|
|
55
|
+
constructor() {
|
|
56
|
+
this.name = ["Figuur"];
|
|
57
|
+
}
|
|
58
|
+
setImageDimensions(imageElement, schaal) {
|
|
59
|
+
const { naturalHeight, naturalWidth } = imageElement;
|
|
60
|
+
imageElement.height = naturalHeight * (schaal / 100);
|
|
61
|
+
imageElement.width = naturalWidth * (schaal / 100);
|
|
62
|
+
}
|
|
63
|
+
onImageLoad(event, schaal) {
|
|
64
|
+
if (event.target instanceof HTMLImageElement && schaal) {
|
|
65
|
+
this.setImageDimensions(event.target, schaal);
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
render(node, { mapNodeToJsx }) {
|
|
69
|
+
var _a, _b, _c, _d, _e, _f, _g;
|
|
70
|
+
const childNodes = Array.from(node.childNodes);
|
|
71
|
+
const titel = (_a = childNodes.find((n) => getNodeName(n) === "Titel")) === null || _a === void 0 ? void 0 : _a.textContent;
|
|
72
|
+
const bron = (_b = childNodes.find((n) => getNodeName(n) === "Bron")) === null || _b === void 0 ? void 0 : _b.childNodes;
|
|
73
|
+
const illustratieNode = childNodes.find((n) => getNodeName(n) === "Illustratie");
|
|
74
|
+
const bijschriftNode = childNodes.find((n) => getNodeName(n) === "Bijschrift");
|
|
75
|
+
if (illustratieNode instanceof Element) {
|
|
76
|
+
const illustratie = {
|
|
77
|
+
naam: illustratieNode.getAttribute("naam"),
|
|
78
|
+
breedte: illustratieNode.getAttribute("breedte"),
|
|
79
|
+
hoogte: illustratieNode.getAttribute("hoogte"),
|
|
80
|
+
uitlijning: illustratieNode.getAttribute("uitlijning"),
|
|
81
|
+
alt: illustratieNode.getAttribute("alt"),
|
|
82
|
+
schaal: illustratieNode.getAttribute("schaal"),
|
|
83
|
+
};
|
|
84
|
+
const bijschrift = bijschriftNode instanceof Element
|
|
85
|
+
? {
|
|
86
|
+
inhoud: bijschriftNode.childNodes,
|
|
87
|
+
locatie: (_c = bijschriftNode.getAttribute("locatie")) !== null && _c !== void 0 ? _c : "onder",
|
|
88
|
+
}
|
|
89
|
+
: undefined;
|
|
90
|
+
return (h("div", { class: `dso-ozon-figuur ${bijschrift ? `bijschrift-${bijschrift.locatie}` : "onder"}` },
|
|
91
|
+
titel && h("span", { class: "figuur-titel" }, titel),
|
|
92
|
+
(bijschrift === null || bijschrift === void 0 ? void 0 : bijschrift.locatie) === "boven" && (h(Bijschrift, { bijschrift: bijschrift, bron: bron, mapNodeToJsx: mapNodeToJsx })),
|
|
93
|
+
h("dso-image-overlay", null,
|
|
94
|
+
titel && (h("div", { slot: "titel" },
|
|
95
|
+
h("span", null, titel))),
|
|
96
|
+
h("img", { src: (_d = illustratie.naam) !== null && _d !== void 0 ? _d : undefined, alt: (_g = (_f = (_e = illustratie.alt) !== null && _e !== void 0 ? _e : titel) !== null && _f !== void 0 ? _f : illustratie.naam) !== null && _g !== void 0 ? _g : undefined, onLoad: (event) => this.onImageLoad(event, Number(illustratie.schaal)) }),
|
|
97
|
+
(bijschrift || bron) && (h("div", { slot: "bijschrift" },
|
|
98
|
+
h(Bijschrift, { bijschrift: bijschrift, bron: bron, mapNodeToJsx: mapNodeToJsx })))),
|
|
99
|
+
((bijschrift === null || bijschrift === void 0 ? void 0 : bijschrift.locatie) === "onder" || (!bijschrift && bron)) && (h(Bijschrift, { bijschrift: bijschrift, bron: bron, mapNodeToJsx: mapNodeToJsx }))));
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
class OzonContentInhoudNode {
|
|
105
|
+
constructor() {
|
|
106
|
+
this.name = ["Inhoud", "ContainerBlocksType", "BlockMixedcontentMetMaximaleInlinesMarkersPopupsType"];
|
|
107
|
+
}
|
|
108
|
+
render(node, { mapNodeToJsx }) {
|
|
109
|
+
return h("div", { class: "dso-rich-content" }, mapNodeToJsx(node.childNodes));
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
class OzonContentInlineTekstAfbeeldingNode {
|
|
114
|
+
constructor() {
|
|
115
|
+
this.name = ["InlineTekstAfbeelding", "Illustratie"];
|
|
116
|
+
}
|
|
117
|
+
render(node) {
|
|
118
|
+
var _a, _b, _c, _d;
|
|
119
|
+
return (h("img", { src: (_a = node.getAttribute("naam")) !== null && _a !== void 0 ? _a : undefined, alt: (_b = node.getAttribute("naam")) !== null && _b !== void 0 ? _b : undefined, height: (_c = node.getAttribute("hoogte")) !== null && _c !== void 0 ? _c : undefined, width: (_d = node.getAttribute("breedte")) !== null && _d !== void 0 ? _d : undefined }));
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
class OzonContentOpschriftNode {
|
|
124
|
+
constructor() {
|
|
125
|
+
this.name = "Opschrift";
|
|
126
|
+
}
|
|
127
|
+
render(node, { mapNodeToJsx }) {
|
|
128
|
+
return h(Fragment, null, mapNodeToJsx(node.childNodes));
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
class OzonContentInlineNodes {
|
|
133
|
+
constructor() {
|
|
134
|
+
this.name = ["sub", "sup", "strong", "b", "u", "i", "br"];
|
|
135
|
+
}
|
|
136
|
+
render(node, { mapNodeToJsx }) {
|
|
137
|
+
if (node.localName === "br") {
|
|
138
|
+
return h("br", null);
|
|
139
|
+
}
|
|
140
|
+
const Tag = node.localName;
|
|
141
|
+
return h(Tag, null, mapNodeToJsx(node.childNodes));
|
|
142
|
+
}
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
class OzonContentIntIoRefNode {
|
|
146
|
+
constructor() {
|
|
147
|
+
this.name = "IntIoRef";
|
|
148
|
+
}
|
|
149
|
+
render(node, { mapNodeToJsx, emitAnchorClick }) {
|
|
150
|
+
const ref = node.getAttribute("ref");
|
|
151
|
+
if (!ref) {
|
|
152
|
+
return mapNodeToJsx(node.childNodes);
|
|
153
|
+
}
|
|
154
|
+
const intRefOnClick = (event) => {
|
|
155
|
+
event.preventDefault();
|
|
156
|
+
const target = event.currentTarget;
|
|
157
|
+
if (!(target instanceof HTMLAnchorElement)) {
|
|
158
|
+
return;
|
|
159
|
+
}
|
|
160
|
+
const { href } = target;
|
|
161
|
+
emitAnchorClick({
|
|
162
|
+
node: this.name,
|
|
163
|
+
href,
|
|
164
|
+
documentComponent: ref,
|
|
165
|
+
originalEvent: event,
|
|
166
|
+
});
|
|
167
|
+
};
|
|
168
|
+
return (h("a", { href: `#${ref}`, onClick: intRefOnClick }, mapNodeToJsx(node.childNodes)));
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
class OzonContentIntRefNode {
|
|
173
|
+
constructor() {
|
|
174
|
+
this.name = "IntRef";
|
|
175
|
+
}
|
|
176
|
+
render(node, { mapNodeToJsx, emitAnchorClick }) {
|
|
177
|
+
const ref = node.getAttribute("ref");
|
|
178
|
+
if (!ref) {
|
|
179
|
+
return mapNodeToJsx(node.childNodes);
|
|
180
|
+
}
|
|
181
|
+
const intRefOnClick = (event) => {
|
|
182
|
+
event.preventDefault();
|
|
183
|
+
const target = event.currentTarget;
|
|
184
|
+
if (!(target instanceof HTMLAnchorElement)) {
|
|
185
|
+
return;
|
|
186
|
+
}
|
|
187
|
+
const { href } = target;
|
|
188
|
+
emitAnchorClick({
|
|
189
|
+
node: this.name,
|
|
190
|
+
href,
|
|
191
|
+
documentComponent: ref,
|
|
192
|
+
originalEvent: event,
|
|
193
|
+
});
|
|
194
|
+
};
|
|
195
|
+
return (h("a", { href: `#${ref}`, onClick: intRefOnClick }, mapNodeToJsx(node.childNodes)));
|
|
196
|
+
}
|
|
197
|
+
}
|
|
198
|
+
|
|
199
|
+
class OzonContentNootNode {
|
|
200
|
+
constructor() {
|
|
201
|
+
this.name = "Noot";
|
|
202
|
+
this.handles = ["NootNummer"];
|
|
203
|
+
}
|
|
204
|
+
identify() {
|
|
205
|
+
return "Noot";
|
|
206
|
+
}
|
|
207
|
+
render(node, { mapNodeToJsx, state: openNoteId, setState }) {
|
|
208
|
+
var _a, _b;
|
|
209
|
+
const noteId = node.getAttribute("id");
|
|
210
|
+
if (!noteId) {
|
|
211
|
+
console.error("Noot node without id", node);
|
|
212
|
+
return h(Fragment, null);
|
|
213
|
+
}
|
|
214
|
+
const noteControlsId = `dso-ozon-note-${noteId}`;
|
|
215
|
+
const childNodes = Array.from(node.childNodes);
|
|
216
|
+
const nootNummer = (_b = (_a = childNodes.find((n) => getNodeName(n) === "NootNummer")) === null || _a === void 0 ? void 0 : _a.textContent) !== null && _b !== void 0 ? _b : noteId;
|
|
217
|
+
return (h(Fragment, null,
|
|
218
|
+
h("sup", null,
|
|
219
|
+
h("button", { type: "button", class: "toggle-note", "aria-describedby": noteControlsId, onClick: () => setState === null || setState === void 0 ? void 0 : setState(openNoteId === noteId ? undefined : noteId), onBlur: () => setState === null || setState === void 0 ? void 0 : setState(undefined), "aria-expanded": openNoteId === noteId ? "true" : "false" }, nootNummer)),
|
|
220
|
+
h("dso-tooltip", { active: openNoteId === noteId, id: noteControlsId, stateless: true, descriptive: true },
|
|
221
|
+
h("span", { role: "section" }, mapNodeToJsx(Array.from(node.querySelectorAll(":scope > Al")))))));
|
|
222
|
+
}
|
|
223
|
+
}
|
|
224
|
+
|
|
225
|
+
function mapColspecs(count, nodeList) {
|
|
226
|
+
const elements = Array.from(nodeList);
|
|
227
|
+
const totalWidth = getTotalWidth(elements);
|
|
228
|
+
return {
|
|
229
|
+
totalWidth,
|
|
230
|
+
count,
|
|
231
|
+
columns: elements.map((element, index) => {
|
|
232
|
+
var _a;
|
|
233
|
+
const colNumber = element.getAttribute("colnum");
|
|
234
|
+
return {
|
|
235
|
+
name: (_a = element.getAttribute("colname")) !== null && _a !== void 0 ? _a : "",
|
|
236
|
+
number: colNumber ? parseInt(colNumber, 10) : index + 1,
|
|
237
|
+
width: getWidth(totalWidth, element),
|
|
238
|
+
};
|
|
239
|
+
}),
|
|
240
|
+
};
|
|
241
|
+
}
|
|
242
|
+
function getTotalWidth(elements) {
|
|
243
|
+
return elements.reduce((totalWidth, element) => {
|
|
244
|
+
var _a, _b;
|
|
245
|
+
const width = (_b = (_a = element.getAttribute("colwidth")) === null || _a === void 0 ? void 0 : _a.replace(/[^0-9]/, "")) !== null && _b !== void 0 ? _b : "";
|
|
246
|
+
const colWidth = parseInt(width, 10);
|
|
247
|
+
return totalWidth + (isNaN(colWidth) ? 0 : colWidth);
|
|
248
|
+
}, 0);
|
|
249
|
+
}
|
|
250
|
+
function getWidth(totalWidth, element) {
|
|
251
|
+
const width = element.getAttribute("colwidth");
|
|
252
|
+
if (!width) {
|
|
253
|
+
return undefined;
|
|
254
|
+
}
|
|
255
|
+
if (width === "*") {
|
|
256
|
+
return "100%";
|
|
257
|
+
}
|
|
258
|
+
if (width.includes("*") || width.match(/^[\d+]$/)) {
|
|
259
|
+
const colWidth = parseInt(width.replace(/[^0-9]/, ""), 10);
|
|
260
|
+
return `${Math.round((colWidth / totalWidth) * 100)}%`;
|
|
261
|
+
}
|
|
262
|
+
return width;
|
|
263
|
+
}
|
|
264
|
+
|
|
265
|
+
const Colgroup = ({ colspecs }) => colspecs.columns.length > 0 ? (h("colgroup", null, colspecs.columns.map((colspec) => (h("col", { style: { width: colspec.width } }))))) : (h(Fragment, null));
|
|
266
|
+
|
|
267
|
+
function getData(cell) {
|
|
268
|
+
return {
|
|
269
|
+
moreRows: cell.getAttribute("morerows"),
|
|
270
|
+
nameStart: cell.getAttribute("namest"),
|
|
271
|
+
nameEnd: cell.getAttribute("nameend"),
|
|
272
|
+
};
|
|
273
|
+
}
|
|
274
|
+
function getColspan({ columns }, nameStart, nameEnd) {
|
|
275
|
+
const colspecStart = columns.find((c) => c.name === nameStart);
|
|
276
|
+
const colspecEnd = columns.find((c) => c.name === nameEnd);
|
|
277
|
+
if (!colspecStart || !colspecEnd) {
|
|
278
|
+
return undefined;
|
|
279
|
+
}
|
|
280
|
+
const colspan = colspecEnd.number - colspecStart.number + 1;
|
|
281
|
+
return colspan === 1 ? undefined : colspan;
|
|
282
|
+
}
|
|
283
|
+
const Cell = ({ context: { mapNodeToJsx }, colspecs, cell }) => {
|
|
284
|
+
const { moreRows, nameStart, nameEnd } = getData(cell);
|
|
285
|
+
const td = {
|
|
286
|
+
rowSpan: moreRows ? parseInt(moreRows, 10) + 1 : undefined,
|
|
287
|
+
colSpan: colspecs && nameStart && nameEnd ? getColspan(colspecs, nameStart, nameEnd) : undefined,
|
|
288
|
+
};
|
|
289
|
+
return h("td", Object.assign({}, td), mapNodeToJsx(cell.childNodes));
|
|
290
|
+
};
|
|
291
|
+
|
|
292
|
+
const Rows = ({ context, colspecs, rows }) => {
|
|
293
|
+
return (h(Fragment, null, rows.map((row) => (h("tr", null, Array.from(row.children).map((cell) => (h(Cell, { cell: cell, colspecs: colspecs, context: context }))))))));
|
|
294
|
+
};
|
|
295
|
+
|
|
296
|
+
function mapData(node) {
|
|
297
|
+
var _a, _b, _c;
|
|
298
|
+
const tgroup = node.querySelector(":scope > tgroup");
|
|
299
|
+
const colAttribute = (_a = tgroup === null || tgroup === void 0 ? void 0 : tgroup.getAttribute("cols")) !== null && _a !== void 0 ? _a : undefined;
|
|
300
|
+
const columnCount = colAttribute ? parseInt(colAttribute, 10) : undefined;
|
|
301
|
+
return {
|
|
302
|
+
caption: (_c = (_b = node.querySelector(":scope > title")) === null || _b === void 0 ? void 0 : _b.textContent) !== null && _c !== void 0 ? _c : undefined,
|
|
303
|
+
colspecs: tgroup && columnCount ? mapColspecs(columnCount, tgroup.querySelectorAll(":scope > colspec")) : undefined,
|
|
304
|
+
headRows: Array.from(node.querySelectorAll(":scope > tgroup > thead > row")),
|
|
305
|
+
bodyRows: Array.from(node.querySelectorAll(":scope > tgroup > tbody > row")),
|
|
306
|
+
};
|
|
307
|
+
}
|
|
308
|
+
class OzonContentTableNode {
|
|
309
|
+
constructor() {
|
|
310
|
+
this.name = "table";
|
|
311
|
+
this.handles = ["title", "tgroup", "colspec", "thead", "tbody", "row", "cell"];
|
|
312
|
+
}
|
|
313
|
+
render(node, context) {
|
|
314
|
+
const { caption, colspecs, headRows, bodyRows } = mapData(node);
|
|
315
|
+
return (h("dso-table", null,
|
|
316
|
+
h("table", { class: "table dso-table-vertical-lines" },
|
|
317
|
+
caption && h("caption", null, caption),
|
|
318
|
+
colspecs && h(Colgroup, { colspecs: colspecs }),
|
|
319
|
+
headRows.length > 0 && (h("thead", null,
|
|
320
|
+
h(Rows, { rows: headRows, colspecs: colspecs, context: context }))),
|
|
321
|
+
bodyRows.length > 0 && (h("tbody", null,
|
|
322
|
+
h(Rows, { rows: bodyRows, colspecs: colspecs, context: context }))))));
|
|
323
|
+
}
|
|
324
|
+
}
|
|
325
|
+
|
|
326
|
+
class OzonContentTextNode {
|
|
327
|
+
constructor() {
|
|
328
|
+
this.name = "#text";
|
|
329
|
+
}
|
|
330
|
+
render(node) {
|
|
331
|
+
return h(Fragment, null, node.textContent);
|
|
332
|
+
}
|
|
333
|
+
}
|
|
334
|
+
|
|
335
|
+
class OzonContentFallbackNode {
|
|
336
|
+
constructor() {
|
|
337
|
+
// This name does not match any elements
|
|
338
|
+
this.name = ["<fallback>"];
|
|
339
|
+
}
|
|
340
|
+
render(node, { mapNodeToJsx }) {
|
|
341
|
+
return h("span", { class: `fallback od-${getNodeName(node)}` }, mapNodeToJsx(node.childNodes));
|
|
342
|
+
}
|
|
343
|
+
}
|
|
344
|
+
|
|
345
|
+
class OzonContentLijstNode {
|
|
346
|
+
constructor() {
|
|
347
|
+
this.name = "Lijst";
|
|
348
|
+
}
|
|
349
|
+
render(node, { mapNodeToJsx }) {
|
|
350
|
+
var _a;
|
|
351
|
+
const childNodes = Array.from(node.childNodes);
|
|
352
|
+
const aanhef = childNodes.find((n) => getNodeName(n) === "Lijstaanhef");
|
|
353
|
+
const sluiting = childNodes.find((n) => getNodeName(n) === "Lijstsluiting");
|
|
354
|
+
const listItems = childNodes.filter((n) => getNodeName(n) === "Li");
|
|
355
|
+
return (h("div", { class: "dso-ozon-lijst od-Lijst" },
|
|
356
|
+
aanhef && mapNodeToJsx(aanhef),
|
|
357
|
+
h("ul", { class: (_a = node.getAttribute("type")) !== null && _a !== void 0 ? _a : "" }, listItems.map((item) => {
|
|
358
|
+
var _a;
|
|
359
|
+
const itemNodes = Array.from(item.childNodes);
|
|
360
|
+
const liNummer = (_a = itemNodes.find((n) => getNodeName(n) === "LiNummer")) === null || _a === void 0 ? void 0 : _a.textContent;
|
|
361
|
+
return (h("li", { class: "od-Li" },
|
|
362
|
+
liNummer && h("span", { class: "od-LiNummer" }, liNummer),
|
|
363
|
+
mapNodeToJsx(itemNodes.filter((n) => getNodeName(n) !== "LiNummer"))));
|
|
364
|
+
})),
|
|
365
|
+
sluiting && mapNodeToJsx(sluiting)));
|
|
366
|
+
}
|
|
367
|
+
}
|
|
368
|
+
|
|
369
|
+
class Mapper {
|
|
370
|
+
constructor() {
|
|
371
|
+
this.mappers = [
|
|
372
|
+
new OzonContentTextNode(),
|
|
373
|
+
new OzonContentDocumentNode(),
|
|
374
|
+
new OzonContentInhoudNode(),
|
|
375
|
+
new OzonContentOpschriftNode(),
|
|
376
|
+
new OzonContentIntRefNode(),
|
|
377
|
+
new OzonContentExtRefNode(),
|
|
378
|
+
new OzonContentAlNode(),
|
|
379
|
+
new OzonContentInlineNodes(),
|
|
380
|
+
new OzonContentInlineTekstAfbeeldingNode(),
|
|
381
|
+
new OzonContentNootNode(),
|
|
382
|
+
new OzonContentTableNode(),
|
|
383
|
+
new OzonContentIntIoRefNode(),
|
|
384
|
+
new OzonContentFiguurNode(),
|
|
385
|
+
new OzonContentLijstNode(),
|
|
386
|
+
];
|
|
387
|
+
this.skip = this.mappers.reduce((t, m) => {
|
|
388
|
+
if (m.handles) {
|
|
389
|
+
t.push(...m.handles);
|
|
390
|
+
}
|
|
391
|
+
return t;
|
|
392
|
+
}, []);
|
|
393
|
+
this.fallbackNode = new OzonContentFallbackNode();
|
|
394
|
+
this.domParser = new DOMParser();
|
|
395
|
+
}
|
|
396
|
+
findMapper(name) {
|
|
397
|
+
var _a;
|
|
398
|
+
if (this.skip.includes(name)) {
|
|
399
|
+
return undefined;
|
|
400
|
+
}
|
|
401
|
+
return ((_a = this.mappers.find((m) => {
|
|
402
|
+
if (Array.isArray(m.name)) {
|
|
403
|
+
return m.name.includes(name);
|
|
404
|
+
}
|
|
405
|
+
return m.name === name;
|
|
406
|
+
})) !== null && _a !== void 0 ? _a : this.fallbackNode);
|
|
407
|
+
}
|
|
408
|
+
mapNodeToJsx(node, context, path) {
|
|
409
|
+
var _a;
|
|
410
|
+
if (node instanceof NodeList) {
|
|
411
|
+
return h(Fragment, null, Array.from(node).map((n) => this.mapNodeToJsx(n, context, path)));
|
|
412
|
+
}
|
|
413
|
+
if (Array.isArray(node)) {
|
|
414
|
+
return h(Fragment, null, node.map((n) => this.mapNodeToJsx(n, context, path)));
|
|
415
|
+
}
|
|
416
|
+
const nodeName = getNodeName(node);
|
|
417
|
+
const mapper = this.findMapper(nodeName);
|
|
418
|
+
if (!mapper) {
|
|
419
|
+
return h(Fragment, null);
|
|
420
|
+
}
|
|
421
|
+
const identity = (_a = mapper.identify) === null || _a === void 0 ? void 0 : _a.call(mapper, node);
|
|
422
|
+
const state = identity ? context.state[identity] : undefined;
|
|
423
|
+
const setState = identity
|
|
424
|
+
? (state) => context.setState(Object.assign(Object.assign({}, context.state), { [identity]: state }))
|
|
425
|
+
: undefined;
|
|
426
|
+
return mapper.render(node, {
|
|
427
|
+
mapNodeToJsx: (n) => this.mapNodeToJsx(n, context, [...path, node]),
|
|
428
|
+
emitAnchorClick: context.emitAnchorClick,
|
|
429
|
+
setState,
|
|
430
|
+
state,
|
|
431
|
+
path,
|
|
432
|
+
});
|
|
433
|
+
}
|
|
434
|
+
transform(xml, context) {
|
|
435
|
+
if (!this.cache || this.cache.xml !== xml) {
|
|
436
|
+
this.cache = { xml, document: this.domParser.parseFromString(xml, "text/xml") };
|
|
437
|
+
}
|
|
438
|
+
const xmlDocument = this.cache.document;
|
|
439
|
+
return this.mapNodeToJsx(xmlDocument.getRootNode(), context, []);
|
|
440
|
+
}
|
|
441
|
+
}
|
|
442
|
+
|
|
443
|
+
const ozonContentCss = ".sc-dso-ozon-content-h:not([inline]) {\n display: block;\n}\n\n[inline].sc-dso-ozon-content-h {\n display: inline;\n}\n\n[deleted].sc-dso-ozon-content-h *.sc-dso-ozon-content {\n text-decoration: line-through !important;\n}\n\n[interactive].sc-dso-ozon-content-h {\n background-color: transparent;\n color: #39870c;\n text-decoration: underline;\n cursor: pointer;\n color: #275937;\n font-weight: 600;\n text-decoration: none;\n}\n[interactive].sc-dso-ozon-content-h:hover, [interactive].sc-dso-ozon-content-h:focus {\n color: #676cb0;\n text-decoration: underline;\n}\n[interactive].sc-dso-ozon-content-h:active {\n text-decoration: none;\n}\n\n[interactive=sub].sc-dso-ozon-content-h {\n color: #191919;\n}\n\n.deleted-start.sc-dso-ozon-content, .deleted-end.sc-dso-ozon-content {\n position: absolute;\n width: 1px;\n height: 1px;\n padding: 0;\n margin: -1px;\n overflow: hidden;\n clip: rect(0, 0, 0, 0);\n border: 0;\n}\n\nbutton.toggle-note.sc-dso-ozon-content {\n display: inline-block;\n font-size: 1em;\n font-weight: 500;\n margin-bottom: 0;\n text-decoration: none;\n touch-action: manipulation;\n text-align: left;\n user-select: none;\n vertical-align: middle;\n border: 0;\n color: #39870c;\n line-height: 1;\n padding: 0;\n background-color: transparent;\n}\nbutton.toggle-note.sc-dso-ozon-content:focus, button.toggle-note.sc-dso-ozon-content:focus-visible {\n outline-offset: 2px;\n}\nbutton.toggle-note.sc-dso-ozon-content:active {\n outline: 0;\n}\nbutton.toggle-note[disabled].sc-dso-ozon-content {\n color: #afcf9d;\n}\nbutton.toggle-note[disabled].dso-spinner-left.sc-dso-ozon-content, button.toggle-note[disabled].dso-spinner-right.sc-dso-ozon-content {\n color: #39870c;\n}\nbutton.toggle-note.sc-dso-ozon-content:not([disabled]):hover {\n color: #676cb0;\n text-decoration: underline;\n text-underline-position: under;\n}\nbutton.toggle-note.sc-dso-ozon-content:not([disabled]):active {\n color: #676cb0;\n}\nbutton.toggle-note.btn-align.sc-dso-ozon-content {\n line-height: calc(1.5em - 1px);\n padding: 11px 0;\n position: relative;\n}\nbutton.toggle-note.dso-spinner-left.sc-dso-ozon-content::before {\n background-image: url(\"data:image/svg+xml,%3Csvg class='spinner' viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg' %3E%3Cstyle%3E .spinner %7B animation: rotator 8s linear infinite; transform-origin: center; %7D @keyframes rotator %7B 0%25 %7B transform: rotate(0deg); %7D 100%25 %7B transform: rotate(360deg); %7D %7D .path %7B stroke-dasharray: 265; stroke-dashoffset: 0; transform-origin: center; stroke: %2339870c; animation: dash 2s ease-in-out infinite; %7D @keyframes dash %7B 0%25 %7B stroke-dashoffset: 265; %7D 50%25 %7B stroke-dashoffset: 65; transform:rotate(90deg); %7D 100%25 %7B stroke-dashoffset: 265; transform:rotate(360deg); %7D %3C/style%3E%3Ccircle class='path' fill='none' stroke-width='10' stroke-linecap='butt' cx='50' cy='50' r='45'%3E%3C/circle%3E%3C/svg%3E\");\n background-repeat: no-repeat;\n content: \"\";\n display: inline-block;\n height: 24px;\n vertical-align: middle;\n width: 24px;\n margin-right: 8px;\n}\nbutton.toggle-note.dso-spinner-right.sc-dso-ozon-content::after {\n background-image: url(\"data:image/svg+xml,%3Csvg class='spinner' viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg' %3E%3Cstyle%3E .spinner %7B animation: rotator 8s linear infinite; transform-origin: center; %7D @keyframes rotator %7B 0%25 %7B transform: rotate(0deg); %7D 100%25 %7B transform: rotate(360deg); %7D %7D .path %7B stroke-dasharray: 265; stroke-dashoffset: 0; transform-origin: center; stroke: %2339870c; animation: dash 2s ease-in-out infinite; %7D @keyframes dash %7B 0%25 %7B stroke-dashoffset: 265; %7D 50%25 %7B stroke-dashoffset: 65; transform:rotate(90deg); %7D 100%25 %7B stroke-dashoffset: 265; transform:rotate(360deg); %7D %3C/style%3E%3Ccircle class='path' fill='none' stroke-width='10' stroke-linecap='butt' cx='50' cy='50' r='45'%3E%3C/circle%3E%3C/svg%3E\");\n background-repeat: no-repeat;\n content: \"\";\n display: inline-block;\n height: 24px;\n vertical-align: middle;\n width: 24px;\n margin-left: 8px;\n}\nbutton.toggle-note.sc-dso-ozon-content dso-icon.sc-dso-ozon-content + span.sc-dso-ozon-content:not(.sr-only), button.toggle-note.sc-dso-ozon-content svg.di.sc-dso-ozon-content + span.sc-dso-ozon-content:not(.sr-only), button.toggle-note.sc-dso-ozon-content span.sc-dso-ozon-content:not(.sr-only) + dso-icon.sc-dso-ozon-content, button.toggle-note.sc-dso-ozon-content span.sc-dso-ozon-content:not(.sr-only) + svg.di.sc-dso-ozon-content {\n margin-left: 8px;\n}\nbutton.toggle-note.sc-dso-ozon-content svg.di.di-chevron-down.sc-dso-ozon-content + span.sc-dso-ozon-content:not(.sr-only), button.toggle-note.sc-dso-ozon-content svg.di.di-chevron-up.sc-dso-ozon-content + span.sc-dso-ozon-content:not(.sr-only), button.toggle-note.sc-dso-ozon-content span.sc-dso-ozon-content:not(.sr-only) + svg.di.di-chevron-down.sc-dso-ozon-content, button.toggle-note.sc-dso-ozon-content span.sc-dso-ozon-content:not(.sr-only) + svg.di.di-chevron-up.sc-dso-ozon-content {\n margin-left: 4px;\n}\nbutton.toggle-note.sc-dso-ozon-content dso-icon[icon=chevron-left].sc-dso-ozon-content + span.sc-dso-ozon-content:not(.sr-only), button.toggle-note.sc-dso-ozon-content dso-icon[icon=chevron-right].sc-dso-ozon-content + span.sc-dso-ozon-content:not(.sr-only), button.toggle-note.sc-dso-ozon-content svg.di.di-angle-down.sc-dso-ozon-content + span.sc-dso-ozon-content:not(.sr-only), button.toggle-note.sc-dso-ozon-content svg.di.di-angle-up.sc-dso-ozon-content + span.sc-dso-ozon-content:not(.sr-only), button.toggle-note.sc-dso-ozon-content span.sc-dso-ozon-content:not(.sr-only) + svg.di.di-angle-down.sc-dso-ozon-content, button.toggle-note.sc-dso-ozon-content span.sc-dso-ozon-content:not(.sr-only) + svg.di.di-angle-up.sc-dso-ozon-content, button.toggle-note.sc-dso-ozon-content span.sc-dso-ozon-content:not(.sr-only) + dso-icon[icon=chevron-left].sc-dso-ozon-content, button.toggle-note.sc-dso-ozon-content span.sc-dso-ozon-content:not(.sr-only) + dso-icon[icon=chevron-right].sc-dso-ozon-content {\n margin-left: 0;\n}\nbutton.toggle-note.sc-dso-ozon-content dso-icon.sc-dso-ozon-content, button.toggle-note.sc-dso-ozon-content svg.di.sc-dso-ozon-content, button.toggle-note.sc-dso-ozon-content span.sc-dso-ozon-content {\n vertical-align: middle;\n}\n\nspan[role=section].sc-dso-ozon-content, span[role=paragraph].sc-dso-ozon-content {\n display: block;\n}\n\n.fallback.sc-dso-ozon-content {\n display: block;\n}\n\n.od-Term.sc-dso-ozon-content {\n font-weight: 700;\n}\n\n.od-Definitie.sc-dso-ozon-content, .od-Tussenkop.sc-dso-ozon-content {\n font-style: italic;\n}\n\n.od-Inhoud.sc-dso-ozon-content, .od-Inhoud.sc-dso-ozon-content > .od-Lijst.sc-dso-ozon-content, .od-IntIoRef.sc-dso-ozon-content, .od-Lidnr.sc-dso-ozon-content, .od-LiNr.sc-dso-ozon-content, .od-Opschrift.sc-dso-ozon-content, .od-Tussenkop.sc-dso-ozon-content {\n display: inline;\n}\n\n.od-Al.sc-dso-ozon-content {\n margin-bottom: 0.75em;\n}\n\n.od-IntIoRef.sc-dso-ozon-content {\n border-bottom: 1px dotted;\n}\n\n.dso-ozon-figuur.sc-dso-ozon-content {\n margin-bottom: 16px;\n}\n.dso-ozon-figuur.sc-dso-ozon-content .figuur-bijschrift.sc-dso-ozon-content {\n display: block;\n font-size: 0.75rem;\n font-style: italic;\n}\n.dso-ozon-figuur.bijschrift-boven.sc-dso-ozon-content .figuur-bijschrift.sc-dso-ozon-content {\n padding-bottom: 0.25rem;\n}\n.dso-ozon-figuur.bijschrift-onder.sc-dso-ozon-content .figuur-bijschrift.sc-dso-ozon-content {\n padding-top: 0.25rem;\n}\n.dso-ozon-figuur.sc-dso-ozon-content .figuur-titel.sc-dso-ozon-content {\n color: #8b4a6a;\n display: block;\n font-weight: 500;\n padding-bottom: 0.5rem;\n}\n\n.dso-ozon-lijst.sc-dso-ozon-content span.od-Lijstaanhef.sc-dso-ozon-content, .dso-ozon-lijst.sc-dso-ozon-content span.od-Lijstsluiting.sc-dso-ozon-content {\n margin-bottom: 1rem;\n}\n.dso-ozon-lijst.sc-dso-ozon-content ul.expliciet.sc-dso-ozon-content {\n list-style: none;\n}\n.dso-ozon-lijst.sc-dso-ozon-content ul.expliciet.sc-dso-ozon-content > .od-Li.sc-dso-ozon-content {\n position: relative;\n}\n.dso-ozon-lijst.sc-dso-ozon-content ul.expliciet.sc-dso-ozon-content > .od-Li.sc-dso-ozon-content > span.od-LiNummer.sc-dso-ozon-content {\n position: absolute;\n left: -44px;\n text-align: right;\n width: 40px;\n}\n\n.od-Tabel.sc-dso-ozon-content thead.sc-dso-ozon-content {\n font-weight: 600;\n}\n\n.od-Kadertekst.sc-dso-ozon-content {\n border: 1px solid #e5e5e5;\n margin-bottom: 1rem;\n padding: 1rem;\n}";
|
|
444
|
+
|
|
445
|
+
const OzonContent = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
|
|
446
|
+
constructor() {
|
|
447
|
+
super();
|
|
448
|
+
this.__registerHost();
|
|
449
|
+
this.dsoAnchorClick = createEvent(this, "dsoAnchorClick", 7);
|
|
450
|
+
this.dsoClick = createEvent(this, "dsoClick", 7);
|
|
451
|
+
this.mapper = new Mapper();
|
|
452
|
+
this.content = undefined;
|
|
453
|
+
this.inline = false;
|
|
454
|
+
this.deleted = false;
|
|
455
|
+
this.interactive = false;
|
|
456
|
+
this.state = {};
|
|
457
|
+
}
|
|
458
|
+
handleHostOnClick(e) {
|
|
459
|
+
// '' is `true`: <dso-ozon-content interactive>
|
|
460
|
+
if (this.interactive !== "" && !this.interactive) {
|
|
461
|
+
return;
|
|
462
|
+
}
|
|
463
|
+
const doIt = e.composedPath().find((e) => e === this.host || (e instanceof HTMLElement && isTabbable(e))) === this.host;
|
|
464
|
+
if (doIt) {
|
|
465
|
+
this.dsoClick.emit({ originalEvent: e });
|
|
466
|
+
}
|
|
467
|
+
}
|
|
468
|
+
render() {
|
|
469
|
+
var _a;
|
|
470
|
+
const context = {
|
|
471
|
+
state: this.state,
|
|
472
|
+
setState: (state) => (this.state = state),
|
|
473
|
+
emitAnchorClick: this.dsoAnchorClick.emit,
|
|
474
|
+
};
|
|
475
|
+
const transformed = this.mapper.transform((_a = this.content) !== null && _a !== void 0 ? _a : "", context);
|
|
476
|
+
if (this.deleted) {
|
|
477
|
+
return (h("section", null, h("slot", { name: "prefix" }), h("span", { class: "deleted-start" }, "Begin verwijderd element"), transformed, h("span", { class: "deleted-end" }, "Einde verwijderd element"), h("slot", { name: "suffix" })));
|
|
478
|
+
}
|
|
479
|
+
return (h(Host, { onClick: (e) => this.handleHostOnClick(e) }, h("slot", { name: "prefix" }), transformed, h("slot", { name: "suffix" })));
|
|
480
|
+
}
|
|
481
|
+
get host() { return this; }
|
|
482
|
+
static get style() { return ozonContentCss; }
|
|
483
|
+
}, [6, "dso-ozon-content", {
|
|
484
|
+
"content": [1],
|
|
485
|
+
"inline": [516],
|
|
486
|
+
"deleted": [516],
|
|
487
|
+
"interactive": [520],
|
|
488
|
+
"state": [32]
|
|
489
|
+
}]);
|
|
490
|
+
function defineCustomElement$1() {
|
|
491
|
+
if (typeof customElements === "undefined") {
|
|
492
|
+
return;
|
|
493
|
+
}
|
|
494
|
+
const components = ["dso-ozon-content"];
|
|
495
|
+
components.forEach(tagName => { switch (tagName) {
|
|
496
|
+
case "dso-ozon-content":
|
|
497
|
+
if (!customElements.get(tagName)) {
|
|
498
|
+
customElements.define(tagName, OzonContent);
|
|
499
|
+
}
|
|
500
|
+
break;
|
|
501
|
+
} });
|
|
502
|
+
}
|
|
503
|
+
|
|
504
|
+
const DsoOzonContent = OzonContent;
|
|
505
|
+
const defineCustomElement = defineCustomElement$1;
|
|
506
|
+
|
|
507
|
+
export { DsoOzonContent, defineCustomElement };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { Components, JSX } from "../types/components";
|
|
2
|
+
|
|
3
|
+
interface DsoPagination extends Components.DsoPagination, HTMLElement {}
|
|
4
|
+
export const DsoPagination: {
|
|
5
|
+
prototype: DsoPagination;
|
|
6
|
+
new (): DsoPagination;
|
|
7
|
+
};
|
|
8
|
+
/**
|
|
9
|
+
* Used to define this component and all nested components recursively.
|
|
10
|
+
*/
|
|
11
|
+
export const defineCustomElement: () => void;
|