@dso-toolkit/core 36.3.0 → 38.1.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-attachments-counter.cjs.entry.js +1 -1
- package/dist/cjs/dso-autosuggest.cjs.entry.js +17 -7
- package/dist/cjs/dso-badge.cjs.entry.js +2 -8
- package/dist/cjs/dso-dropdown-menu.cjs.entry.js +11 -28
- package/dist/cjs/dso-header.cjs.entry.js +1 -1
- package/dist/cjs/dso-helpcenter-panel.cjs.entry.js +2 -2
- package/dist/cjs/dso-highlight-box.cjs.entry.js +1 -1
- package/dist/cjs/dso-icon.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 +1 -1
- package/dist/cjs/dso-map-controls.cjs.entry.js +1 -1
- package/dist/cjs/dso-ozon-content.cjs.entry.js +48 -5
- package/dist/cjs/dso-toggletip.cjs.entry.js +1 -2
- package/dist/cjs/dso-toolkit.cjs.js +1 -1
- package/dist/cjs/dso-tooltip.cjs.entry.js +5 -1
- package/dist/cjs/dso-viewer-grid.cjs.entry.js +6 -2
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/components/attachments-counter/attachments-counter.css +2 -2
- package/dist/collection/components/autosuggest/autosuggest.css +11 -2
- package/dist/collection/components/autosuggest/autosuggest.js +55 -8
- package/dist/collection/components/autosuggest/autosuggest.template.js +4 -1
- package/dist/collection/components/badge/badge.css +5 -0
- package/dist/collection/components/badge/badge.js +2 -11
- package/dist/collection/components/dropdown-menu/dropdown-menu.js +12 -30
- package/dist/collection/components/header/header.css +6 -6
- package/dist/collection/components/helpcenter-panel/helpcenter-panel.css +13 -12
- package/dist/collection/components/helpcenter-panel/helpcenter-panel.js +4 -4
- package/dist/collection/components/highlight-box/highlight-box.css +5 -2
- package/dist/collection/components/icon/icon.css +2 -2
- package/dist/collection/components/image-overlay/image-overlay.css +8 -8
- package/dist/collection/components/info/info.css +2 -2
- package/dist/collection/components/map-controls/map-controls.css +12 -12
- package/dist/collection/components/ozon-content/nodes/al.node.js +4 -1
- package/dist/collection/components/ozon-content/nodes/inhoud.node.js +0 -1
- package/dist/collection/components/ozon-content/nodes/noot.node.js +1 -1
- package/dist/collection/components/ozon-content/nodes/opschrift.node.js +9 -0
- package/dist/collection/components/ozon-content/ozon-content-mapper.js +2 -0
- package/dist/collection/components/ozon-content/ozon-content.css +39 -5
- package/dist/collection/components/ozon-content/ozon-content.js +110 -3
- package/dist/collection/components/ozon-content/ozon-content.template.js +6 -1
- package/dist/collection/components/selectable/selectable.template.js +1 -1
- package/dist/collection/components/toggletip/toggletip.js +1 -2
- package/dist/collection/components/tooltip/tooltip.js +24 -2
- package/dist/collection/components/tooltip/tooltip.template.js +2 -2
- package/dist/collection/components/viewer-grid/viewer-grid.css +16 -16
- package/dist/collection/components/viewer-grid/viewer-grid.js +27 -1
- package/dist/collection/components/viewer-grid/viewer-grid.template.js +4 -1
- package/dist/custom-elements/index.js +102 -66
- package/dist/dso-toolkit/dso-toolkit.css +1 -1
- package/dist/dso-toolkit/dso-toolkit.esm.js +1 -1
- package/dist/dso-toolkit/{p-af8a4337.entry.js → p-076400f4.entry.js} +1 -1
- package/dist/dso-toolkit/{p-d6c47662.entry.js → p-14fc5767.entry.js} +1 -1
- package/dist/dso-toolkit/{p-7b67e324.entry.js → p-150fe323.entry.js} +1 -1
- package/dist/dso-toolkit/{p-121c3588.entry.js → p-1894c7ae.entry.js} +1 -1
- package/dist/dso-toolkit/{p-b29184e1.entry.js → p-1e92e29d.entry.js} +1 -1
- package/dist/dso-toolkit/p-2f64bded.entry.js +1 -0
- package/dist/dso-toolkit/p-49938275.entry.js +1 -0
- package/dist/dso-toolkit/{p-efa4a33d.entry.js → p-5a56d726.entry.js} +1 -1
- package/dist/dso-toolkit/p-6ec616ee.entry.js +1 -0
- package/dist/dso-toolkit/p-7f41f2a1.entry.js +1 -0
- package/dist/dso-toolkit/p-a8cf15cf.entry.js +1 -0
- package/dist/dso-toolkit/{p-4f904355.entry.js → p-c0b7f435.entry.js} +1 -1
- package/dist/dso-toolkit/p-c32860a3.entry.js +1 -0
- package/dist/dso-toolkit/p-d76c1151.entry.js +1 -0
- package/dist/dso-toolkit/p-e1496a15.entry.js +1 -0
- package/dist/esm/dso-attachments-counter.entry.js +1 -1
- package/dist/esm/dso-autosuggest.entry.js +17 -7
- package/dist/esm/dso-badge.entry.js +2 -8
- package/dist/esm/dso-dropdown-menu.entry.js +12 -29
- package/dist/esm/dso-header.entry.js +1 -1
- package/dist/esm/dso-helpcenter-panel.entry.js +2 -2
- package/dist/esm/dso-highlight-box.entry.js +1 -1
- package/dist/esm/dso-icon.entry.js +1 -1
- package/dist/esm/dso-image-overlay.entry.js +1 -1
- package/dist/esm/dso-info_2.entry.js +1 -1
- package/dist/esm/dso-map-controls.entry.js +1 -1
- package/dist/esm/dso-ozon-content.entry.js +49 -6
- package/dist/esm/dso-toggletip.entry.js +1 -2
- package/dist/esm/dso-toolkit.js +1 -1
- package/dist/esm/dso-tooltip.entry.js +5 -1
- package/dist/esm/dso-viewer-grid.entry.js +6 -2
- package/dist/esm/loader.js +1 -1
- package/dist/types/components/autosuggest/autosuggest.d.ts +8 -0
- package/dist/types/components/autosuggest/autosuggest.template.d.ts +1 -1
- package/dist/types/components/badge/badge.d.ts +1 -2
- package/dist/types/components/dropdown-menu/dropdown-menu.d.ts +0 -3
- package/dist/types/components/ozon-content/nodes/opschrift.node.d.ts +6 -0
- package/dist/types/components/ozon-content/ozon-content.d.ts +25 -1
- package/dist/types/components/ozon-content/ozon-content.interfaces.d.ts +3 -0
- package/dist/types/components/ozon-content/ozon-content.template.d.ts +1 -1
- package/dist/types/components/tooltip/tooltip.d.ts +4 -0
- package/dist/types/components/tooltip/tooltip.template.d.ts +1 -1
- package/dist/types/components/viewer-grid/viewer-grid.d.ts +4 -0
- package/dist/types/components/viewer-grid/viewer-grid.template.d.ts +1 -1
- package/dist/types/components.d.ts +69 -3
- package/package.json +10 -11
- package/dist/dso-toolkit/p-1a3db1cd.entry.js +0 -1
- package/dist/dso-toolkit/p-1fd3d18d.entry.js +0 -1
- package/dist/dso-toolkit/p-2a611af3.entry.js +0 -1
- package/dist/dso-toolkit/p-72e47943.entry.js +0 -1
- package/dist/dso-toolkit/p-a58b3108.entry.js +0 -1
- package/dist/dso-toolkit/p-a93e9760.entry.js +0 -1
- package/dist/dso-toolkit/p-d1f62081.entry.js +0 -1
- package/dist/dso-toolkit/p-efb7575f.entry.js +0 -1
|
@@ -115,9 +115,9 @@ button::-moz-focus-inner {
|
|
|
115
115
|
background: var(--dso-icon, var(--di-download)) no-repeat;
|
|
116
116
|
background-position: center;
|
|
117
117
|
background-size: cover;
|
|
118
|
-
height:
|
|
118
|
+
height: 24px;
|
|
119
119
|
vertical-align: top;
|
|
120
|
-
width:
|
|
120
|
+
width: 24px;
|
|
121
121
|
}
|
|
122
122
|
#toggle-visibility-button.download:hover::after {
|
|
123
123
|
--dso-icon: var(--di-download-wit);
|
|
@@ -129,9 +129,9 @@ button::-moz-focus-inner {
|
|
|
129
129
|
background: var(--dso-icon, var(--di-external-link)) no-repeat;
|
|
130
130
|
background-position: center;
|
|
131
131
|
background-size: cover;
|
|
132
|
-
height:
|
|
132
|
+
height: 24px;
|
|
133
133
|
vertical-align: top;
|
|
134
|
-
width:
|
|
134
|
+
width: 24px;
|
|
135
135
|
}
|
|
136
136
|
#toggle-visibility-button.extern:hover::after {
|
|
137
137
|
--dso-icon: var(--di-external-link-wit);
|
|
@@ -236,9 +236,9 @@ button::-moz-focus-inner {
|
|
|
236
236
|
background: var(--dso-icon, var(--di-download)) no-repeat;
|
|
237
237
|
background-position: center;
|
|
238
238
|
background-size: cover;
|
|
239
|
-
height:
|
|
239
|
+
height: 24px;
|
|
240
240
|
vertical-align: top;
|
|
241
|
-
width:
|
|
241
|
+
width: 24px;
|
|
242
242
|
}
|
|
243
243
|
#zoom-buttons button.download:hover::after {
|
|
244
244
|
--dso-icon: var(--di-download-wit);
|
|
@@ -250,9 +250,9 @@ button::-moz-focus-inner {
|
|
|
250
250
|
background: var(--dso-icon, var(--di-external-link)) no-repeat;
|
|
251
251
|
background-position: center;
|
|
252
252
|
background-size: cover;
|
|
253
|
-
height:
|
|
253
|
+
height: 24px;
|
|
254
254
|
vertical-align: top;
|
|
255
|
-
width:
|
|
255
|
+
width: 24px;
|
|
256
256
|
}
|
|
257
257
|
#zoom-buttons button.extern:hover::after {
|
|
258
258
|
--dso-icon: var(--di-external-link-wit);
|
|
@@ -340,9 +340,9 @@ button::-moz-focus-inner {
|
|
|
340
340
|
background: var(--dso-icon, var(--di-download)) no-repeat;
|
|
341
341
|
background-position: center;
|
|
342
342
|
background-size: cover;
|
|
343
|
-
height:
|
|
343
|
+
height: 24px;
|
|
344
344
|
vertical-align: top;
|
|
345
|
-
width:
|
|
345
|
+
width: 24px;
|
|
346
346
|
}
|
|
347
347
|
#close-button.download[disabled]::after {
|
|
348
348
|
--dso-icon: var(--di-download-grasgroen-40);
|
|
@@ -354,9 +354,9 @@ button::-moz-focus-inner {
|
|
|
354
354
|
background: var(--dso-icon, var(--di-external-link)) no-repeat;
|
|
355
355
|
background-position: center;
|
|
356
356
|
background-size: cover;
|
|
357
|
-
height:
|
|
357
|
+
height: 24px;
|
|
358
358
|
vertical-align: top;
|
|
359
|
-
width:
|
|
359
|
+
width: 24px;
|
|
360
360
|
}
|
|
361
361
|
#close-button.extern[disabled]::after {
|
|
362
362
|
--dso-icon: var(--di-external-link-grasgroen-40);
|
|
@@ -5,7 +5,10 @@ export class OzonContentAlNode {
|
|
|
5
5
|
this.name = 'Al';
|
|
6
6
|
}
|
|
7
7
|
render(node, { mapNodeToJsx, path }) {
|
|
8
|
-
const nestedAl = path.some(node =>
|
|
8
|
+
const nestedAl = path.some(node => {
|
|
9
|
+
const nodeName = getNodeName(node);
|
|
10
|
+
return nodeName === 'Al' || nodeName === 'Opschrift';
|
|
11
|
+
});
|
|
9
12
|
const content = mapNodeToJsx(node.childNodes);
|
|
10
13
|
return nestedAl
|
|
11
14
|
? h("span", { role: "paragraph" }, content)
|
|
@@ -21,7 +21,7 @@ export class OzonContentNootNode {
|
|
|
21
21
|
return (h(Fragment, null,
|
|
22
22
|
h("sup", null,
|
|
23
23
|
h("button", { type: "button", class: "toggle-note", id: 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)),
|
|
24
|
-
h("dso-tooltip", { active: openNoteId === noteId, for: noteControlsId, stateless: true },
|
|
24
|
+
h("dso-tooltip", { active: openNoteId === noteId, for: noteControlsId, stateless: true, descriptive: true },
|
|
25
25
|
h("span", { role: "section" }, mapNodeToJsx(Array.from(node.querySelectorAll(':scope > Al')))))));
|
|
26
26
|
}
|
|
27
27
|
}
|
|
@@ -4,6 +4,7 @@ import { OzonContentDocumentNode } from './nodes/document.node';
|
|
|
4
4
|
import { OzonContentExtRefNode } from './nodes/ext-ref.node';
|
|
5
5
|
import { OzonContentIllustratieNode } from './nodes/illustratie.node';
|
|
6
6
|
import { OzonContentInhoudNode } from './nodes/inhoud.node';
|
|
7
|
+
import { OzonContentOpschriftNode } from './nodes/opschrift.node';
|
|
7
8
|
import { OzonContentInlineNodes } from './nodes/inline.nodes';
|
|
8
9
|
import { OzonContentIntRefNode } from './nodes/int-ref.node';
|
|
9
10
|
import { OzonContentNootNode } from './nodes/noot.node';
|
|
@@ -17,6 +18,7 @@ export class Mapper {
|
|
|
17
18
|
new OzonContentTextNode(),
|
|
18
19
|
new OzonContentDocumentNode(),
|
|
19
20
|
new OzonContentInhoudNode(),
|
|
21
|
+
new OzonContentOpschriftNode(),
|
|
20
22
|
new OzonContentIntRefNode(),
|
|
21
23
|
new OzonContentExtRefNode(),
|
|
22
24
|
new OzonContentAlNode(),
|
|
@@ -1,7 +1,41 @@
|
|
|
1
|
-
:host {
|
|
1
|
+
:host(:not([inline])) {
|
|
2
2
|
display: block;
|
|
3
3
|
}
|
|
4
4
|
|
|
5
|
+
:host([inline]) {
|
|
6
|
+
display: inline;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
:host([deleted]) * {
|
|
10
|
+
text-decoration: line-through !important;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
:host([interactive]) {
|
|
14
|
+
background-color: transparent;
|
|
15
|
+
color: #39870c;
|
|
16
|
+
text-decoration: underline;
|
|
17
|
+
cursor: pointer;
|
|
18
|
+
}
|
|
19
|
+
:host([interactive]):hover, :host([interactive]):focus {
|
|
20
|
+
color: #676cb0;
|
|
21
|
+
text-decoration: underline;
|
|
22
|
+
}
|
|
23
|
+
:host([interactive]):active {
|
|
24
|
+
text-decoration: none;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
.deleted-start,
|
|
28
|
+
.deleted-end {
|
|
29
|
+
position: absolute;
|
|
30
|
+
width: 1px;
|
|
31
|
+
height: 1px;
|
|
32
|
+
padding: 0;
|
|
33
|
+
margin: -1px;
|
|
34
|
+
overflow: hidden;
|
|
35
|
+
clip: rect(0, 0, 0, 0);
|
|
36
|
+
border: 0;
|
|
37
|
+
}
|
|
38
|
+
|
|
5
39
|
button.toggle-note {
|
|
6
40
|
display: inline-block;
|
|
7
41
|
font-size: 1em;
|
|
@@ -55,9 +89,9 @@ button.toggle-note.download::after {
|
|
|
55
89
|
background: var(--dso-icon, var(--di-download)) no-repeat;
|
|
56
90
|
background-position: center;
|
|
57
91
|
background-size: cover;
|
|
58
|
-
height:
|
|
92
|
+
height: 24px;
|
|
59
93
|
vertical-align: top;
|
|
60
|
-
width:
|
|
94
|
+
width: 24px;
|
|
61
95
|
}
|
|
62
96
|
button.toggle-note.download[disabled]::after {
|
|
63
97
|
--dso-icon: var(--di-download-grasgroen-40);
|
|
@@ -69,9 +103,9 @@ button.toggle-note.extern::after {
|
|
|
69
103
|
background: var(--dso-icon, var(--di-external-link)) no-repeat;
|
|
70
104
|
background-position: center;
|
|
71
105
|
background-size: cover;
|
|
72
|
-
height:
|
|
106
|
+
height: 24px;
|
|
73
107
|
vertical-align: top;
|
|
74
|
-
width:
|
|
108
|
+
width: 24px;
|
|
75
109
|
}
|
|
76
110
|
button.toggle-note.extern[disabled]::after {
|
|
77
111
|
--dso-icon: var(--di-external-link-grasgroen-40);
|
|
@@ -1,10 +1,35 @@
|
|
|
1
|
-
import { Component, Event, Prop, State, } from '@stencil/core';
|
|
1
|
+
import { h, Component, Element, Event, Prop, State, Host } from '@stencil/core';
|
|
2
|
+
import { isTabbable } from 'tabbable';
|
|
2
3
|
import { Mapper } from './ozon-content-mapper';
|
|
3
4
|
export class OzonContent {
|
|
4
5
|
constructor() {
|
|
6
|
+
/**
|
|
7
|
+
* Setting this property creates dso-ozon-content as inline element instead of a block element.
|
|
8
|
+
*/
|
|
9
|
+
this.inline = false;
|
|
10
|
+
/**
|
|
11
|
+
* Marks content as deleted using visual and accessible clues.
|
|
12
|
+
*/
|
|
13
|
+
this.deleted = false;
|
|
14
|
+
/**
|
|
15
|
+
* Visualize the component as interactive. This means that the component will emit `dsoClick` events when the user clicks non-interactive elements.
|
|
16
|
+
*
|
|
17
|
+
* **Do not** use this without an accessible companion element! `interactive` is only
|
|
18
|
+
* meant to ease the use of the companion element for mouse/touch users.
|
|
19
|
+
*/
|
|
20
|
+
this.interactive = false;
|
|
5
21
|
this.state = {};
|
|
6
22
|
this.mapper = new Mapper();
|
|
7
23
|
}
|
|
24
|
+
handleHostOnClick(e) {
|
|
25
|
+
if (!this.interactive) {
|
|
26
|
+
return;
|
|
27
|
+
}
|
|
28
|
+
const doIt = e.composedPath().find(e => e === this.host || (e instanceof HTMLElement && isTabbable(e))) === this.host;
|
|
29
|
+
if (doIt) {
|
|
30
|
+
this.dsoClick.emit({ originalEvent: e });
|
|
31
|
+
}
|
|
32
|
+
}
|
|
8
33
|
render() {
|
|
9
34
|
var _a;
|
|
10
35
|
const context = {
|
|
@@ -12,7 +37,14 @@ export class OzonContent {
|
|
|
12
37
|
setState: state => this.state = state,
|
|
13
38
|
emitAnchorClick: this.anchorClick.emit
|
|
14
39
|
};
|
|
15
|
-
|
|
40
|
+
const transformed = this.mapper.transform((_a = this.content) !== null && _a !== void 0 ? _a : '', context);
|
|
41
|
+
if (this.deleted) {
|
|
42
|
+
return (h("section", null,
|
|
43
|
+
h("span", { class: "deleted-start" }, "Begin verwijderd element"),
|
|
44
|
+
transformed,
|
|
45
|
+
h("span", { class: "deleted-end" }, "Einde verwijderd element")));
|
|
46
|
+
}
|
|
47
|
+
return (h(Host, { onClick: (e) => this.handleHostOnClick(e) }, transformed));
|
|
16
48
|
}
|
|
17
49
|
static get is() { return "dso-ozon-content"; }
|
|
18
50
|
static get encapsulation() { return "scoped"; }
|
|
@@ -35,10 +67,64 @@ export class OzonContent {
|
|
|
35
67
|
"optional": false,
|
|
36
68
|
"docs": {
|
|
37
69
|
"tags": [],
|
|
38
|
-
"text": ""
|
|
70
|
+
"text": "The XML to be rendered."
|
|
39
71
|
},
|
|
40
72
|
"attribute": "content",
|
|
41
73
|
"reflect": false
|
|
74
|
+
},
|
|
75
|
+
"inline": {
|
|
76
|
+
"type": "boolean",
|
|
77
|
+
"mutable": false,
|
|
78
|
+
"complexType": {
|
|
79
|
+
"original": "boolean",
|
|
80
|
+
"resolved": "boolean",
|
|
81
|
+
"references": {}
|
|
82
|
+
},
|
|
83
|
+
"required": false,
|
|
84
|
+
"optional": false,
|
|
85
|
+
"docs": {
|
|
86
|
+
"tags": [],
|
|
87
|
+
"text": "Setting this property creates dso-ozon-content as inline element instead of a block element."
|
|
88
|
+
},
|
|
89
|
+
"attribute": "inline",
|
|
90
|
+
"reflect": true,
|
|
91
|
+
"defaultValue": "false"
|
|
92
|
+
},
|
|
93
|
+
"deleted": {
|
|
94
|
+
"type": "boolean",
|
|
95
|
+
"mutable": false,
|
|
96
|
+
"complexType": {
|
|
97
|
+
"original": "boolean",
|
|
98
|
+
"resolved": "boolean",
|
|
99
|
+
"references": {}
|
|
100
|
+
},
|
|
101
|
+
"required": false,
|
|
102
|
+
"optional": false,
|
|
103
|
+
"docs": {
|
|
104
|
+
"tags": [],
|
|
105
|
+
"text": "Marks content as deleted using visual and accessible clues."
|
|
106
|
+
},
|
|
107
|
+
"attribute": "deleted",
|
|
108
|
+
"reflect": true,
|
|
109
|
+
"defaultValue": "false"
|
|
110
|
+
},
|
|
111
|
+
"interactive": {
|
|
112
|
+
"type": "boolean",
|
|
113
|
+
"mutable": false,
|
|
114
|
+
"complexType": {
|
|
115
|
+
"original": "boolean",
|
|
116
|
+
"resolved": "boolean",
|
|
117
|
+
"references": {}
|
|
118
|
+
},
|
|
119
|
+
"required": false,
|
|
120
|
+
"optional": false,
|
|
121
|
+
"docs": {
|
|
122
|
+
"tags": [],
|
|
123
|
+
"text": "Visualize the component as interactive. This means that the component will emit `dsoClick` events when the user clicks non-interactive elements.\n\n**Do not** use this without an accessible companion element! `interactive` is only\nmeant to ease the use of the companion element for mouse/touch users."
|
|
124
|
+
},
|
|
125
|
+
"attribute": "interactive",
|
|
126
|
+
"reflect": true,
|
|
127
|
+
"defaultValue": "false"
|
|
42
128
|
}
|
|
43
129
|
}; }
|
|
44
130
|
static get states() { return {
|
|
@@ -64,5 +150,26 @@ export class OzonContent {
|
|
|
64
150
|
}
|
|
65
151
|
}
|
|
66
152
|
}
|
|
153
|
+
}, {
|
|
154
|
+
"method": "dsoClick",
|
|
155
|
+
"name": "dsoClick",
|
|
156
|
+
"bubbles": true,
|
|
157
|
+
"cancelable": true,
|
|
158
|
+
"composed": true,
|
|
159
|
+
"docs": {
|
|
160
|
+
"tags": [],
|
|
161
|
+
"text": "These events are only emitted when the component is `interactive`."
|
|
162
|
+
},
|
|
163
|
+
"complexType": {
|
|
164
|
+
"original": "OzonContentClick",
|
|
165
|
+
"resolved": "OzonContentClick",
|
|
166
|
+
"references": {
|
|
167
|
+
"OzonContentClick": {
|
|
168
|
+
"location": "import",
|
|
169
|
+
"path": "./ozon-content.interfaces"
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
}
|
|
67
173
|
}]; }
|
|
174
|
+
static get elementRef() { return "host"; }
|
|
68
175
|
}
|
|
@@ -1,9 +1,14 @@
|
|
|
1
1
|
import { html } from 'lit-html';
|
|
2
|
-
|
|
2
|
+
import { ifDefined } from 'lit-html/directives/if-defined.js';
|
|
3
|
+
export function ozonContentTemplate({ content, inline, interactive, deleted, onAnchorClick, onClick }) {
|
|
3
4
|
return html `
|
|
4
5
|
<dso-ozon-content
|
|
5
6
|
.content=${content}
|
|
7
|
+
?inline=${inline}
|
|
8
|
+
?interactive=${interactive}
|
|
9
|
+
?deleted=${deleted}
|
|
6
10
|
@anchorClick=${onAnchorClick}
|
|
11
|
+
@dsoClick=${ifDefined(interactive ? onClick : undefined)}
|
|
7
12
|
></dso-ozon-content>
|
|
8
13
|
`;
|
|
9
14
|
}
|
|
@@ -15,7 +15,7 @@ export function selectableTemplate({ type, id, name, label, value, required, inv
|
|
|
15
15
|
?checked=${checked}
|
|
16
16
|
?indeterminate=${indeterminate}
|
|
17
17
|
?info-fixed=${info === null || info === void 0 ? void 0 : info.fixed}
|
|
18
|
-
@dsoChange=${(e) => onChange(e.detail)}
|
|
18
|
+
@dsoChange=${(e) => onChange === null || onChange === void 0 ? void 0 : onChange(e.detail)}
|
|
19
19
|
>
|
|
20
20
|
${label}
|
|
21
21
|
${(_a = info === null || info === void 0 ? void 0 : info.richContent) !== null && _a !== void 0 ? _a : nothing}
|
|
@@ -43,12 +43,11 @@ export class Toggletip {
|
|
|
43
43
|
throw Error("button not found");
|
|
44
44
|
}
|
|
45
45
|
this.button = button;
|
|
46
|
-
this.host.setAttribute("tabindex", "-1");
|
|
47
46
|
}
|
|
48
47
|
render() {
|
|
49
48
|
return (h(Fragment, null,
|
|
50
49
|
h("dso-info-button", { id: "toggle", onClick: this.click, label: this.label, active: this.active, secondary: this.secondary }),
|
|
51
|
-
h("dso-tooltip", { stateless: true, for: "toggle", active: this.active, position: this.position, small: this.small },
|
|
50
|
+
h("dso-tooltip", { stateless: true, descriptive: true, for: "toggle", active: this.active, position: this.position, small: this.small },
|
|
52
51
|
h("slot", null))));
|
|
53
52
|
}
|
|
54
53
|
static get is() { return "dso-toggletip"; }
|
|
@@ -6,6 +6,10 @@ import clsx from 'clsx';
|
|
|
6
6
|
const transitionDuration = 150;
|
|
7
7
|
export class Tooltip {
|
|
8
8
|
constructor() {
|
|
9
|
+
/**
|
|
10
|
+
* Defines if the tooltip is descriptive. A descriptive tooltip contains a meaningful message. Tooltips that are not descriptive are hidden from screenreaders using `aria-hidden`.
|
|
11
|
+
*/
|
|
12
|
+
this.descriptive = false;
|
|
9
13
|
/**
|
|
10
14
|
* Set position of tooltip relative to target
|
|
11
15
|
*/
|
|
@@ -123,9 +127,9 @@ export class Tooltip {
|
|
|
123
127
|
}
|
|
124
128
|
render() {
|
|
125
129
|
return (h(Host, { class: { 'hidden': this.hidden } },
|
|
126
|
-
h("div", { class: clsx('tooltip', { in: this.active })
|
|
130
|
+
h("div", { class: clsx('tooltip', { in: this.active }) },
|
|
127
131
|
!this.noArrow && h("div", { "data-popper-arrow": true, class: "tooltip-arrow" }),
|
|
128
|
-
h("div", { class: clsx('tooltip-inner', { 'dso-small': this.small }) },
|
|
132
|
+
h("div", { "aria-hidden": !this.descriptive || undefined, class: clsx('tooltip-inner', { 'dso-small': this.small }) },
|
|
129
133
|
h("slot", null)))));
|
|
130
134
|
}
|
|
131
135
|
getTarget() {
|
|
@@ -158,6 +162,24 @@ export class Tooltip {
|
|
|
158
162
|
"$": ["tooltip.css"]
|
|
159
163
|
}; }
|
|
160
164
|
static get properties() { return {
|
|
165
|
+
"descriptive": {
|
|
166
|
+
"type": "boolean",
|
|
167
|
+
"mutable": false,
|
|
168
|
+
"complexType": {
|
|
169
|
+
"original": "boolean",
|
|
170
|
+
"resolved": "boolean",
|
|
171
|
+
"references": {}
|
|
172
|
+
},
|
|
173
|
+
"required": false,
|
|
174
|
+
"optional": false,
|
|
175
|
+
"docs": {
|
|
176
|
+
"tags": [],
|
|
177
|
+
"text": "Defines if the tooltip is descriptive. A descriptive tooltip contains a meaningful message. Tooltips that are not descriptive are hidden from screenreaders using `aria-hidden`."
|
|
178
|
+
},
|
|
179
|
+
"attribute": "descriptive",
|
|
180
|
+
"reflect": true,
|
|
181
|
+
"defaultValue": "false"
|
|
182
|
+
},
|
|
161
183
|
"position": {
|
|
162
184
|
"type": "string",
|
|
163
185
|
"mutable": false,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { html } from 'lit-html';
|
|
2
2
|
import { ifDefined } from 'lit-html/directives/if-defined.js';
|
|
3
|
-
export function tooltipTemplate({ active, position, label, id }) {
|
|
4
|
-
return html `<dso-tooltip position=${position} for=${ifDefined(id)} ?active=${active}>
|
|
3
|
+
export function tooltipTemplate({ active, descriptive, position, label, id }) {
|
|
4
|
+
return html `<dso-tooltip ?descriptive=${ifDefined(descriptive)} position=${position} for=${ifDefined(id)} ?active=${active}>
|
|
5
5
|
${label}
|
|
6
6
|
</dso-tooltip>`;
|
|
7
7
|
}
|
|
@@ -232,9 +232,9 @@ h6,
|
|
|
232
232
|
background: var(--dso-icon, var(--di-download)) no-repeat;
|
|
233
233
|
background-position: center;
|
|
234
234
|
background-size: cover;
|
|
235
|
-
height:
|
|
235
|
+
height: 24px;
|
|
236
236
|
vertical-align: top;
|
|
237
|
-
width:
|
|
237
|
+
width: 24px;
|
|
238
238
|
}
|
|
239
239
|
.shrink.download[disabled]::after,
|
|
240
240
|
.expand.download[disabled]::after,
|
|
@@ -254,9 +254,9 @@ h6,
|
|
|
254
254
|
background: var(--dso-icon, var(--di-external-link)) no-repeat;
|
|
255
255
|
background-position: center;
|
|
256
256
|
background-size: cover;
|
|
257
|
-
height:
|
|
257
|
+
height: 24px;
|
|
258
258
|
vertical-align: top;
|
|
259
|
-
width:
|
|
259
|
+
width: 24px;
|
|
260
260
|
}
|
|
261
261
|
.shrink.extern[disabled]::after,
|
|
262
262
|
.expand.extern[disabled]::after,
|
|
@@ -423,9 +423,9 @@ h6,
|
|
|
423
423
|
background: var(--dso-icon, var(--di-download)) no-repeat;
|
|
424
424
|
background-position: center;
|
|
425
425
|
background-size: cover;
|
|
426
|
-
height:
|
|
426
|
+
height: 24px;
|
|
427
427
|
vertical-align: top;
|
|
428
|
-
width:
|
|
428
|
+
width: 24px;
|
|
429
429
|
}
|
|
430
430
|
.sizing-buttons button.download:hover::after {
|
|
431
431
|
--dso-icon: var(--di-download-wit);
|
|
@@ -437,9 +437,9 @@ h6,
|
|
|
437
437
|
background: var(--dso-icon, var(--di-external-link)) no-repeat;
|
|
438
438
|
background-position: center;
|
|
439
439
|
background-size: cover;
|
|
440
|
-
height:
|
|
440
|
+
height: 24px;
|
|
441
441
|
vertical-align: top;
|
|
442
|
-
width:
|
|
442
|
+
width: 24px;
|
|
443
443
|
}
|
|
444
444
|
.sizing-buttons button.extern:hover::after {
|
|
445
445
|
--dso-icon: var(--di-external-link-wit);
|
|
@@ -601,9 +601,9 @@ h6,
|
|
|
601
601
|
background: var(--dso-icon, var(--di-download)) no-repeat;
|
|
602
602
|
background-position: center;
|
|
603
603
|
background-size: cover;
|
|
604
|
-
height:
|
|
604
|
+
height: 24px;
|
|
605
605
|
vertical-align: top;
|
|
606
|
-
width:
|
|
606
|
+
width: 24px;
|
|
607
607
|
}
|
|
608
608
|
.filterpanel-buttons .cancel-button.download:hover::after {
|
|
609
609
|
--dso-icon: var(--di-download-wit);
|
|
@@ -615,9 +615,9 @@ h6,
|
|
|
615
615
|
background: var(--dso-icon, var(--di-external-link)) no-repeat;
|
|
616
616
|
background-position: center;
|
|
617
617
|
background-size: cover;
|
|
618
|
-
height:
|
|
618
|
+
height: 24px;
|
|
619
619
|
vertical-align: top;
|
|
620
|
-
width:
|
|
620
|
+
width: 24px;
|
|
621
621
|
}
|
|
622
622
|
.filterpanel-buttons .cancel-button.extern:hover::after {
|
|
623
623
|
--dso-icon: var(--di-external-link-wit);
|
|
@@ -702,17 +702,17 @@ h6,
|
|
|
702
702
|
background: var(--dso-icon, var(--di-download-wit)) no-repeat;
|
|
703
703
|
background-position: center;
|
|
704
704
|
background-size: cover;
|
|
705
|
-
height:
|
|
705
|
+
height: 24px;
|
|
706
706
|
vertical-align: top;
|
|
707
|
-
width:
|
|
707
|
+
width: 24px;
|
|
708
708
|
}
|
|
709
709
|
.filterpanel-buttons .apply-button.extern::after {
|
|
710
710
|
background: var(--dso-icon, var(--di-external-link-wit)) no-repeat;
|
|
711
711
|
background-position: center;
|
|
712
712
|
background-size: cover;
|
|
713
|
-
height:
|
|
713
|
+
height: 24px;
|
|
714
714
|
vertical-align: top;
|
|
715
|
-
width:
|
|
715
|
+
width: 24px;
|
|
716
716
|
}
|
|
717
717
|
.filterpanel-buttons .apply-button dso-icon,
|
|
718
718
|
.filterpanel-buttons .apply-button svg.di {
|
|
@@ -6,7 +6,11 @@ export class ViewerGrid {
|
|
|
6
6
|
constructor() {
|
|
7
7
|
this.filterpanelOpen = false;
|
|
8
8
|
this.overlayOpen = false;
|
|
9
|
-
|
|
9
|
+
/**
|
|
10
|
+
* Size of the main content panel when component loads. Changing this attribute afterwards has no effect.
|
|
11
|
+
*/
|
|
12
|
+
this.initialMainSize = "large";
|
|
13
|
+
this.mainSize = this.initialMainSize;
|
|
10
14
|
this.filterpanelSlot = null;
|
|
11
15
|
this.overlaySlot = null;
|
|
12
16
|
this.shrinkMain = () => {
|
|
@@ -163,6 +167,28 @@ export class ViewerGrid {
|
|
|
163
167
|
"attribute": "overlay-open",
|
|
164
168
|
"reflect": true,
|
|
165
169
|
"defaultValue": "false"
|
|
170
|
+
},
|
|
171
|
+
"initialMainSize": {
|
|
172
|
+
"type": "string",
|
|
173
|
+
"mutable": false,
|
|
174
|
+
"complexType": {
|
|
175
|
+
"original": "MainSize",
|
|
176
|
+
"resolved": "\"large\" | \"medium\" | \"small\"",
|
|
177
|
+
"references": {
|
|
178
|
+
"MainSize": {
|
|
179
|
+
"location": "global"
|
|
180
|
+
}
|
|
181
|
+
}
|
|
182
|
+
},
|
|
183
|
+
"required": false,
|
|
184
|
+
"optional": false,
|
|
185
|
+
"docs": {
|
|
186
|
+
"tags": [],
|
|
187
|
+
"text": "Size of the main content panel when component loads. Changing this attribute afterwards has no effect."
|
|
188
|
+
},
|
|
189
|
+
"attribute": "initial-main-size",
|
|
190
|
+
"reflect": false,
|
|
191
|
+
"defaultValue": "\"large\""
|
|
166
192
|
}
|
|
167
193
|
}; }
|
|
168
194
|
static get states() { return {
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
import { html } from "lit-html";
|
|
2
|
-
|
|
2
|
+
import { ifDefined } from 'lit-html/directives/if-defined.js';
|
|
3
|
+
export function viewerGridTemplate({ filterpanel, main, map, overlay, noOverlay, filterpanelOpen, overlayOpen, initialMainSize, mainSizeChange, filterpanelApply, filterpanelCancel, closeOverlay, }) {
|
|
3
4
|
return noOverlay
|
|
4
5
|
? html `
|
|
5
6
|
<dso-viewer-grid
|
|
6
7
|
?overlay-open=${overlayOpen}
|
|
8
|
+
initial-main-size=${ifDefined(initialMainSize)}
|
|
7
9
|
@closeOverlay=${closeOverlay}
|
|
8
10
|
>
|
|
9
11
|
<div slot="main">${main}</div>
|
|
@@ -14,6 +16,7 @@ export function viewerGridTemplate({ filterpanel, main, map, overlay, noOverlay,
|
|
|
14
16
|
<dso-viewer-grid
|
|
15
17
|
?filterpanel-open=${filterpanelOpen}
|
|
16
18
|
?overlay-open=${overlayOpen}
|
|
19
|
+
initial-main-size=${ifDefined(initialMainSize)}
|
|
17
20
|
@mainSizeChange=${mainSizeChange}
|
|
18
21
|
@closeOverlay=${closeOverlay}
|
|
19
22
|
@filterpanelApply=${filterpanelApply}
|