@gemeente-tilburg/components-react 0.0.0-stage → 0.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/LICENSE.md +288 -0
- package/README.md +28 -2
- package/dist/Accordion.d.ts +24 -0
- package/dist/Alert.d.ts +26 -0
- package/dist/AlertDialog.d.ts +13 -0
- package/dist/Article.d.ts +5 -0
- package/dist/BadgeStatus.d.ts +10 -0
- package/dist/Breadcrumb.d.ts +17 -0
- package/dist/Button.d.ts +13 -0
- package/dist/ButtonGroup.d.ts +7 -0
- package/dist/ButtonLink.d.ts +11 -0
- package/dist/Checkbox.d.ts +7 -0
- package/dist/Combobox.d.ts +41 -0
- package/dist/DataList.d.ts +20 -0
- package/dist/Document.d.ts +5 -0
- package/dist/Fieldset.d.ts +8 -0
- package/dist/FormField.d.ts +11 -0
- package/dist/FormFieldDescription.d.ts +9 -0
- package/dist/FormLabel.d.ts +11 -0
- package/dist/Heading1.d.ts +6 -0
- package/dist/Heading2.d.ts +6 -0
- package/dist/Heading3.d.ts +6 -0
- package/dist/Heading4.d.ts +6 -0
- package/dist/Heading5.d.ts +6 -0
- package/dist/Heading6.d.ts +6 -0
- package/dist/HtmlContent.d.ts +6 -0
- package/dist/LanguageToggle.d.ts +12 -0
- package/dist/Link.d.ts +10 -0
- package/dist/LoadingSpinner.d.ts +9 -0
- package/dist/Modal.d.ts +19 -0
- package/dist/OrderedList.d.ts +8 -0
- package/dist/Page.d.ts +5 -0
- package/dist/PageContent.d.ts +5 -0
- package/dist/PageFooter.d.ts +13 -0
- package/dist/PageHeader.d.ts +13 -0
- package/dist/Pagination.d.ts +25 -0
- package/dist/Paragraph.d.ts +8 -0
- package/dist/PasswordInput.d.ts +15 -0
- package/dist/ProgressBar.d.ts +13 -0
- package/dist/RadioButton.d.ts +6 -0
- package/dist/Select.d.ts +9 -0
- package/dist/Separator.d.ts +6 -0
- package/dist/SkipLink.d.ts +18 -0
- package/dist/Table.d.ts +36 -0
- package/dist/Textarea.d.ts +6 -0
- package/dist/Textbox.d.ts +6 -0
- package/dist/Tooltip.d.ts +23 -0
- package/dist/UnorderedList.d.ts +10 -0
- package/dist/ValidationMessage.d.ts +13 -0
- package/dist/index.cjs.js +1 -0
- package/dist/index.d.ts +94 -0
- package/dist/index.esm.js +1560 -0
- package/dist/style.css +1 -0
- package/package.json +83 -3
|
@@ -0,0 +1,1560 @@
|
|
|
1
|
+
import { jsx as r, jsxs as N, Fragment as ve } from "react/jsx-runtime";
|
|
2
|
+
import d from "clsx";
|
|
3
|
+
import { forwardRef as s, createElement as F, useCallback as A, useState as R, useRef as M, useEffect as B, useImperativeHandle as ce, useId as V, useMemo as W, Children as _e, isValidElement as Ne, cloneElement as ye } from "react";
|
|
4
|
+
const j = s(
|
|
5
|
+
({ className: e, children: a, ...t }, i) => F(
|
|
6
|
+
"utrecht-heading-1",
|
|
7
|
+
{ className: e },
|
|
8
|
+
/* @__PURE__ */ r("h1", { ref: i, className: "utrecht-heading-1", ...t, children: a })
|
|
9
|
+
)
|
|
10
|
+
);
|
|
11
|
+
j.displayName = "Heading1";
|
|
12
|
+
const Y = s(
|
|
13
|
+
({ className: e, children: a, ...t }, i) => F(
|
|
14
|
+
"utrecht-heading-2",
|
|
15
|
+
{ className: e },
|
|
16
|
+
/* @__PURE__ */ r("h2", { ref: i, className: "utrecht-heading-2", ...t, children: a })
|
|
17
|
+
)
|
|
18
|
+
);
|
|
19
|
+
Y.displayName = "Heading2";
|
|
20
|
+
const z = s(
|
|
21
|
+
({ className: e, children: a, ...t }, i) => F(
|
|
22
|
+
"utrecht-heading-3",
|
|
23
|
+
{ className: e },
|
|
24
|
+
/* @__PURE__ */ r("h3", { ref: i, className: "utrecht-heading-3", ...t, children: a })
|
|
25
|
+
)
|
|
26
|
+
);
|
|
27
|
+
z.displayName = "Heading3";
|
|
28
|
+
const q = s(
|
|
29
|
+
({ className: e, children: a, ...t }, i) => F(
|
|
30
|
+
"utrecht-heading-4",
|
|
31
|
+
{ className: e },
|
|
32
|
+
/* @__PURE__ */ r("h4", { ref: i, className: "utrecht-heading-4", ...t, children: a })
|
|
33
|
+
)
|
|
34
|
+
);
|
|
35
|
+
q.displayName = "Heading4";
|
|
36
|
+
const X = s(
|
|
37
|
+
({ className: e, children: a, ...t }, i) => F(
|
|
38
|
+
"utrecht-heading-5",
|
|
39
|
+
{ className: e },
|
|
40
|
+
/* @__PURE__ */ r("h5", { ref: i, className: "utrecht-heading-5", ...t, children: a })
|
|
41
|
+
)
|
|
42
|
+
);
|
|
43
|
+
X.displayName = "Heading5";
|
|
44
|
+
const K = s(
|
|
45
|
+
({ className: e, children: a, ...t }, i) => F(
|
|
46
|
+
"utrecht-heading-6",
|
|
47
|
+
{ className: e },
|
|
48
|
+
/* @__PURE__ */ r("h6", { ref: i, className: "utrecht-heading-6", ...t, children: a })
|
|
49
|
+
)
|
|
50
|
+
);
|
|
51
|
+
K.displayName = "Heading6";
|
|
52
|
+
const xe = { 1: j, 2: Y, 3: z, 4: q, 5: X, 6: K }, ke = ["ArrowDown", "ArrowUp", "Home", "End"], Le = s(
|
|
53
|
+
({
|
|
54
|
+
headingLevel: e = 2,
|
|
55
|
+
displayName: a,
|
|
56
|
+
"aria-label": t,
|
|
57
|
+
className: i,
|
|
58
|
+
children: n,
|
|
59
|
+
onKeyDown: l,
|
|
60
|
+
...o
|
|
61
|
+
}, c) => {
|
|
62
|
+
const u = xe[e], h = A(
|
|
63
|
+
(f) => {
|
|
64
|
+
if (l == null || l(f), f.defaultPrevented || !ke.includes(f.key)) return;
|
|
65
|
+
const x = f.target;
|
|
66
|
+
if (!(x instanceof HTMLButtonElement) || !x.classList.contains("utrecht-accordion__button")) return;
|
|
67
|
+
const k = f.currentTarget;
|
|
68
|
+
if (x.closest(".utrecht-accordion") !== k) return;
|
|
69
|
+
const p = Array.from(
|
|
70
|
+
k.querySelectorAll(".utrecht-accordion__section button.utrecht-accordion__button")
|
|
71
|
+
).filter((L) => !L.disabled && L.closest(".utrecht-accordion") === k), g = p.indexOf(x);
|
|
72
|
+
if (g === -1 || p.length === 0) return;
|
|
73
|
+
let m;
|
|
74
|
+
switch (f.key) {
|
|
75
|
+
case "ArrowDown":
|
|
76
|
+
m = (g + 1) % p.length;
|
|
77
|
+
break;
|
|
78
|
+
case "ArrowUp":
|
|
79
|
+
m = (g - 1 + p.length) % p.length;
|
|
80
|
+
break;
|
|
81
|
+
case "Home":
|
|
82
|
+
m = 0;
|
|
83
|
+
break;
|
|
84
|
+
case "End":
|
|
85
|
+
m = p.length - 1;
|
|
86
|
+
break;
|
|
87
|
+
}
|
|
88
|
+
f.preventDefault(), p[m].focus();
|
|
89
|
+
},
|
|
90
|
+
[l]
|
|
91
|
+
);
|
|
92
|
+
return /* @__PURE__ */ N(
|
|
93
|
+
"div",
|
|
94
|
+
{
|
|
95
|
+
ref: c,
|
|
96
|
+
className: d("utrecht-accordion", i),
|
|
97
|
+
"aria-label": t,
|
|
98
|
+
role: t ? "region" : void 0,
|
|
99
|
+
onKeyDown: h,
|
|
100
|
+
...o,
|
|
101
|
+
children: [
|
|
102
|
+
a && /* @__PURE__ */ r(u, { className: "tilburg-accordion__display-name", children: a }),
|
|
103
|
+
n
|
|
104
|
+
]
|
|
105
|
+
}
|
|
106
|
+
);
|
|
107
|
+
}
|
|
108
|
+
);
|
|
109
|
+
Le.displayName = "Accordion";
|
|
110
|
+
const we = s(
|
|
111
|
+
({
|
|
112
|
+
sectionKey: e,
|
|
113
|
+
label: a,
|
|
114
|
+
expanded: t = !1,
|
|
115
|
+
disabled: i = !1,
|
|
116
|
+
autoToggle: n = !1,
|
|
117
|
+
iconCollapsed: l,
|
|
118
|
+
iconExpanded: o,
|
|
119
|
+
onToggle: c,
|
|
120
|
+
className: u,
|
|
121
|
+
children: h,
|
|
122
|
+
...f
|
|
123
|
+
}, x) => {
|
|
124
|
+
const [k, p] = R(t), g = n ? k : t, m = A(() => {
|
|
125
|
+
if (i) return;
|
|
126
|
+
const v = !g;
|
|
127
|
+
n && p(v), c == null || c(v);
|
|
128
|
+
}, [i, g, n, c]), L = `utrecht-accordion-${e ?? ""}-panel`, w = `utrecht-accordion-${e ?? ""}-button`;
|
|
129
|
+
return /* @__PURE__ */ N("div", { ref: x, className: d("utrecht-accordion__section", u), ...f, children: [
|
|
130
|
+
/* @__PURE__ */ r("span", { className: "utrecht-accordion__header", children: /* @__PURE__ */ N(
|
|
131
|
+
"button",
|
|
132
|
+
{
|
|
133
|
+
className: "utrecht-button utrecht-button--subtle utrecht-accordion__button",
|
|
134
|
+
id: w,
|
|
135
|
+
type: "button",
|
|
136
|
+
disabled: i,
|
|
137
|
+
"aria-expanded": g,
|
|
138
|
+
"aria-controls": L,
|
|
139
|
+
onClick: m,
|
|
140
|
+
children: [
|
|
141
|
+
/* @__PURE__ */ r("span", { className: "utrecht-accordion__button-icon", "aria-hidden": "true", children: g ? o ?? "−" : l ?? "+" }),
|
|
142
|
+
/* @__PURE__ */ r("span", { className: "utrecht-accordion__button-label tilburg-accordion__display-name", children: a })
|
|
143
|
+
]
|
|
144
|
+
}
|
|
145
|
+
) }),
|
|
146
|
+
/* @__PURE__ */ r(
|
|
147
|
+
"div",
|
|
148
|
+
{
|
|
149
|
+
className: "utrecht-accordion__panel",
|
|
150
|
+
id: L,
|
|
151
|
+
"aria-labelledby": w,
|
|
152
|
+
hidden: !g,
|
|
153
|
+
role: "region",
|
|
154
|
+
children: h
|
|
155
|
+
}
|
|
156
|
+
)
|
|
157
|
+
] });
|
|
158
|
+
}
|
|
159
|
+
);
|
|
160
|
+
we.displayName = "AccordionSection";
|
|
161
|
+
/* @license CC0-1.0 */
|
|
162
|
+
const Ce = "position:absolute;inline-size:1px;block-size:1px;margin:-1px;padding:0;overflow:hidden;clip-path:inset(50%);white-space:nowrap;border:0", Ee = 100, J = /* @__PURE__ */ new Map(), Ae = (e) => {
|
|
163
|
+
const a = `tilburg-announcer-${e}`;
|
|
164
|
+
let t = document.getElementById(a);
|
|
165
|
+
return t || (t = document.createElement("div"), t.id = a, t.setAttribute("aria-live", e), t.setAttribute("aria-atomic", "true"), t.setAttribute("style", Ce), document.body.appendChild(t)), t;
|
|
166
|
+
};
|
|
167
|
+
function Te(e, a = "polite") {
|
|
168
|
+
const t = String(e || "").replace(/\s+/g, " ").trim();
|
|
169
|
+
if (typeof document > "u" || !document.body || !t) return;
|
|
170
|
+
const i = Ae(a);
|
|
171
|
+
i.textContent = "", clearTimeout(J.get(a)), J.set(
|
|
172
|
+
a,
|
|
173
|
+
setTimeout(() => {
|
|
174
|
+
i.textContent = t;
|
|
175
|
+
}, Ee)
|
|
176
|
+
);
|
|
177
|
+
}
|
|
178
|
+
const Se = {
|
|
179
|
+
info: "info",
|
|
180
|
+
success: "ok",
|
|
181
|
+
warning: "warning",
|
|
182
|
+
danger: "error"
|
|
183
|
+
}, Ie = { 1: j, 2: Y, 3: z, 4: q, 5: X, 6: K }, Me = () => /* @__PURE__ */ r("svg", { width: "1em", height: "1em", viewBox: "0 0 24 24", fill: "currentColor", "aria-hidden": "true", children: /* @__PURE__ */ r("path", { d: "M12 2a10 10 0 1 0 0 20 10 10 0 0 0 0-20Zm1 15h-2v-6h2v6Zm0-8h-2V7h2v2Z" }) }), De = () => /* @__PURE__ */ r("svg", { width: "1em", height: "1em", viewBox: "0 0 24 24", fill: "currentColor", "aria-hidden": "true", children: /* @__PURE__ */ r("path", { d: "M12 2a10 10 0 1 0 0 20 10 10 0 0 0 0-20Zm-1.4 14.6L6 12l1.4-1.4 3.2 3.2 6-6L18 9.2l-7.4 7.4Z" }) }), Be = () => /* @__PURE__ */ r("svg", { width: "1em", height: "1em", viewBox: "0 0 24 24", fill: "currentColor", "aria-hidden": "true", children: /* @__PURE__ */ r("path", { d: "M1 21h22L12 2 1 21Zm12-3h-2v-2h2v2Zm0-4h-2v-4h2v4Z" }) }), He = () => /* @__PURE__ */ r("svg", { width: "1em", height: "1em", viewBox: "0 0 24 24", fill: "currentColor", "aria-hidden": "true", children: /* @__PURE__ */ r("path", { d: "M12 2a10 10 0 1 0 0 20 10 10 0 0 0 0-20Zm5 13.6L15.6 17 12 13.4 8.4 17 7 15.6 10.6 12 7 8.4 8.4 7 12 10.6 15.6 7 17 8.4 13.4 12 17 15.6Z" }) }), Pe = () => /* @__PURE__ */ r("svg", { width: "1em", height: "1em", viewBox: "0 0 24 24", fill: "currentColor", "aria-hidden": "true", children: /* @__PURE__ */ r("path", { d: "m18.3 5.71-1.42-1.42L12 9.17 7.12 4.29 5.71 5.71 10.59 10.59 5.71 15.46l1.41 1.42L12 12l4.88 4.88 1.42-1.42-4.88-4.87 4.87-4.88Z" }) }), Re = {
|
|
184
|
+
info: /* @__PURE__ */ r(Me, {}),
|
|
185
|
+
success: /* @__PURE__ */ r(De, {}),
|
|
186
|
+
warning: /* @__PURE__ */ r(Be, {}),
|
|
187
|
+
danger: /* @__PURE__ */ r(He, {})
|
|
188
|
+
}, Q = ({ children: e }) => /* @__PURE__ */ r(
|
|
189
|
+
"i",
|
|
190
|
+
{
|
|
191
|
+
"aria-hidden": "true",
|
|
192
|
+
style: {
|
|
193
|
+
alignItems: "center",
|
|
194
|
+
display: "inline-flex",
|
|
195
|
+
fontSize: "var(--utrecht-alert-icon-size, 1.5rem)",
|
|
196
|
+
fontStyle: "normal",
|
|
197
|
+
justifyContent: "center"
|
|
198
|
+
},
|
|
199
|
+
children: e
|
|
200
|
+
}
|
|
201
|
+
), Fe = {
|
|
202
|
+
info: "Informatie:",
|
|
203
|
+
success: "Succes:",
|
|
204
|
+
warning: "Waarschuwing:",
|
|
205
|
+
danger: "Fout:"
|
|
206
|
+
}, $e = s(
|
|
207
|
+
({
|
|
208
|
+
variant: e = "info",
|
|
209
|
+
title: a,
|
|
210
|
+
headingLevel: t = 3,
|
|
211
|
+
closable: i = !1,
|
|
212
|
+
liveRegion: n,
|
|
213
|
+
closeButtonAriaLabel: l = "sluit alert",
|
|
214
|
+
srPrefix: o,
|
|
215
|
+
announce: c = !1,
|
|
216
|
+
icon: u,
|
|
217
|
+
closeIcon: h,
|
|
218
|
+
onClose: f,
|
|
219
|
+
className: x,
|
|
220
|
+
children: k,
|
|
221
|
+
...p
|
|
222
|
+
}, g) => {
|
|
223
|
+
const m = Ie[t], L = u === void 0 ? Re[e] : u, w = h === void 0 ? /* @__PURE__ */ r(Pe, {}) : h, v = o === void 0 ? Fe[e] : o, E = e === "danger" ? "alert" : "status", S = n ?? (e === "danger" ? "assertive" : "polite"), _ = M(null), I = M(""), D = (C) => {
|
|
224
|
+
_.current = C, typeof g == "function" ? g(C) : g && (g.current = C);
|
|
225
|
+
};
|
|
226
|
+
return B(() => {
|
|
227
|
+
var P;
|
|
228
|
+
if (!c || S === "off") return;
|
|
229
|
+
const C = (P = _.current) == null ? void 0 : P.querySelector(".utrecht-alert__content"), H = Array.from((C == null ? void 0 : C.children) ?? [], ($) => {
|
|
230
|
+
var O;
|
|
231
|
+
return ((O = $.textContent) == null ? void 0 : O.trim()) ?? "";
|
|
232
|
+
}).filter(Boolean).join(" ");
|
|
233
|
+
H && H !== I.current && (I.current = H, Te(H, S));
|
|
234
|
+
}), /* @__PURE__ */ N(
|
|
235
|
+
"div",
|
|
236
|
+
{
|
|
237
|
+
ref: D,
|
|
238
|
+
role: c ? void 0 : E,
|
|
239
|
+
"aria-live": c ? void 0 : S,
|
|
240
|
+
"aria-atomic": c ? void 0 : "true",
|
|
241
|
+
className: d("utrecht-alert", "tilburg-alert", `utrecht-alert--${Se[e]}`, x),
|
|
242
|
+
...p,
|
|
243
|
+
children: [
|
|
244
|
+
/* @__PURE__ */ r("div", { className: "utrecht-alert__icon", children: L && /* @__PURE__ */ r(Q, { children: L }) }),
|
|
245
|
+
/* @__PURE__ */ N("div", { className: "utrecht-alert__content", children: [
|
|
246
|
+
a && /* @__PURE__ */ r(m, { className: "tilburg-alert__title", children: a }),
|
|
247
|
+
/* @__PURE__ */ N("div", { className: "utrecht-alert__message", children: [
|
|
248
|
+
v && /* @__PURE__ */ N("span", { className: "utrecht-visually-hidden", children: [
|
|
249
|
+
v,
|
|
250
|
+
" "
|
|
251
|
+
] }),
|
|
252
|
+
k
|
|
253
|
+
] })
|
|
254
|
+
] }),
|
|
255
|
+
i && /* @__PURE__ */ r("button", { type: "button", className: "tilburg-alert__close", "aria-label": l, onClick: f, children: w && /* @__PURE__ */ r(Q, { children: w }) })
|
|
256
|
+
]
|
|
257
|
+
}
|
|
258
|
+
);
|
|
259
|
+
}
|
|
260
|
+
);
|
|
261
|
+
$e.displayName = "Alert";
|
|
262
|
+
const Oe = {
|
|
263
|
+
"primary-action-button": "utrecht-button--primary-action",
|
|
264
|
+
"secondary-action-button": "utrecht-button--secondary-action",
|
|
265
|
+
"subtle-button": "utrecht-button--subtle"
|
|
266
|
+
}, se = s(
|
|
267
|
+
({
|
|
268
|
+
appearance: e,
|
|
269
|
+
size: a = "medium",
|
|
270
|
+
pressed: t,
|
|
271
|
+
busy: i,
|
|
272
|
+
disabled: n,
|
|
273
|
+
type: l = "button",
|
|
274
|
+
title: o,
|
|
275
|
+
"aria-label": c,
|
|
276
|
+
className: u,
|
|
277
|
+
children: h,
|
|
278
|
+
...f
|
|
279
|
+
}, x) => /* @__PURE__ */ r(
|
|
280
|
+
"button",
|
|
281
|
+
{
|
|
282
|
+
ref: x,
|
|
283
|
+
type: l,
|
|
284
|
+
disabled: n,
|
|
285
|
+
title: o,
|
|
286
|
+
"aria-label": c ?? o,
|
|
287
|
+
"aria-pressed": t === void 0 ? void 0 : t ? "true" : "false",
|
|
288
|
+
className: d(
|
|
289
|
+
"utrecht-button",
|
|
290
|
+
`tilburg-${a}`,
|
|
291
|
+
e && Oe[e],
|
|
292
|
+
i && "utrecht-button--busy",
|
|
293
|
+
n && "utrecht-button--disabled",
|
|
294
|
+
t === !0 && "utrecht-button--pressed",
|
|
295
|
+
l === "submit" && "utrecht-button--submit",
|
|
296
|
+
u
|
|
297
|
+
),
|
|
298
|
+
...f,
|
|
299
|
+
children: h
|
|
300
|
+
}
|
|
301
|
+
)
|
|
302
|
+
);
|
|
303
|
+
se.displayName = "Button";
|
|
304
|
+
const Ze = () => /* @__PURE__ */ r("svg", { "aria-hidden": "true", width: "20", height: "20", viewBox: "0 0 20 20", fill: "currentColor", children: /* @__PURE__ */ r("path", { d: "M5 5l10 10M15 5L5 15", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round" }) }), de = s(
|
|
305
|
+
({
|
|
306
|
+
id: e,
|
|
307
|
+
title: a,
|
|
308
|
+
open: t,
|
|
309
|
+
closeLabel: i = "Sluiten",
|
|
310
|
+
closeOnBackdropClick: n = !0,
|
|
311
|
+
footer: l,
|
|
312
|
+
onClose: o,
|
|
313
|
+
onClick: c,
|
|
314
|
+
className: u,
|
|
315
|
+
children: h,
|
|
316
|
+
...f
|
|
317
|
+
}, x) => {
|
|
318
|
+
const k = M(null);
|
|
319
|
+
ce(x, () => k.current);
|
|
320
|
+
const p = V(), g = `${e ?? `tilburg-modal-${p.replace(/:/g, "")}`}-title`;
|
|
321
|
+
B(() => {
|
|
322
|
+
const v = k.current;
|
|
323
|
+
!v || t === void 0 || (t && !v.open && v.showModal(), !t && v.open && v.close());
|
|
324
|
+
}, [t]);
|
|
325
|
+
const m = () => {
|
|
326
|
+
var v;
|
|
327
|
+
return (v = k.current) == null ? void 0 : v.close();
|
|
328
|
+
}, L = (v) => {
|
|
329
|
+
c == null || c(v), n && v.target === v.currentTarget && m();
|
|
330
|
+
}, w = (v) => {
|
|
331
|
+
v.target === v.currentTarget && (o == null || o());
|
|
332
|
+
};
|
|
333
|
+
return /* @__PURE__ */ N(
|
|
334
|
+
"dialog",
|
|
335
|
+
{
|
|
336
|
+
...f,
|
|
337
|
+
ref: k,
|
|
338
|
+
id: e,
|
|
339
|
+
className: d("tilburg-modal", u),
|
|
340
|
+
"aria-labelledby": g,
|
|
341
|
+
onClick: L,
|
|
342
|
+
onClose: w,
|
|
343
|
+
children: [
|
|
344
|
+
/* @__PURE__ */ N("header", { className: "tilburg-modal__header", children: [
|
|
345
|
+
/* @__PURE__ */ r("h2", { id: g, children: a }),
|
|
346
|
+
/* @__PURE__ */ N("button", { type: "button", className: "tilburg-modal__close-button", onClick: m, children: [
|
|
347
|
+
/* @__PURE__ */ r("span", { children: i }),
|
|
348
|
+
/* @__PURE__ */ r(Ze, {})
|
|
349
|
+
] })
|
|
350
|
+
] }),
|
|
351
|
+
/* @__PURE__ */ r("div", { className: "tilburg-modal__content", children: h }),
|
|
352
|
+
l && /* @__PURE__ */ r("footer", { className: "tilburg-modal__footer", children: l })
|
|
353
|
+
]
|
|
354
|
+
}
|
|
355
|
+
);
|
|
356
|
+
}
|
|
357
|
+
);
|
|
358
|
+
de.displayName = "Modal";
|
|
359
|
+
const Ge = (e) => {
|
|
360
|
+
var a;
|
|
361
|
+
return (a = e.currentTarget.closest("dialog")) == null ? void 0 : a.close();
|
|
362
|
+
}, Ve = s(
|
|
363
|
+
({ id: e, title: a, children: t, customFooter: i }, n) => /* @__PURE__ */ r(
|
|
364
|
+
de,
|
|
365
|
+
{
|
|
366
|
+
ref: n,
|
|
367
|
+
id: e,
|
|
368
|
+
title: a,
|
|
369
|
+
footer: i ?? /* @__PURE__ */ r(se, { appearance: "primary-action-button", onClick: Ge, children: "Sluiten" }),
|
|
370
|
+
children: t
|
|
371
|
+
}
|
|
372
|
+
)
|
|
373
|
+
);
|
|
374
|
+
Ve.displayName = "AlertDialog";
|
|
375
|
+
const We = s(
|
|
376
|
+
({ className: e, children: a, ...t }, i) => /* @__PURE__ */ r("article", { ref: i, className: d("utrecht-article", e), ...t, children: a })
|
|
377
|
+
);
|
|
378
|
+
We.displayName = "Article";
|
|
379
|
+
const Ue = /* @__PURE__ */ new Set(["danger", "error", "invalid"]), je = s(
|
|
380
|
+
({ status: e, liveRegion: a, className: t, children: i, ...n }, l) => {
|
|
381
|
+
const o = !!(e && Ue.has(e));
|
|
382
|
+
return /* @__PURE__ */ r(
|
|
383
|
+
"span",
|
|
384
|
+
{
|
|
385
|
+
ref: l,
|
|
386
|
+
role: o ? "alert" : "status",
|
|
387
|
+
"aria-live": a ?? (o ? "assertive" : "polite"),
|
|
388
|
+
className: d("utrecht-badge-status", e && `utrecht-badge-status--${e}`, t),
|
|
389
|
+
...n,
|
|
390
|
+
children: i
|
|
391
|
+
}
|
|
392
|
+
);
|
|
393
|
+
}
|
|
394
|
+
);
|
|
395
|
+
je.displayName = "BadgeStatus";
|
|
396
|
+
const Ye = s(
|
|
397
|
+
({ items: e = [], ariaLabel: a = "Kruimelpad", onItemClick: t, ...i }, n) => e.length ? /* @__PURE__ */ r("nav", { ref: n, "aria-label": a, className: "utrecht-breadcrumb-nav tilburg-breadcrumb", ...i, children: /* @__PURE__ */ r("ol", { className: "utrecht-breadcrumb-nav__list utrecht-breadcrumb-nav__list--html-ol", children: e.map((l, o) => {
|
|
398
|
+
const u = !(o === e.length - 1) && !l.current;
|
|
399
|
+
return /* @__PURE__ */ r("li", { className: "utrecht-breadcrumb-nav__item", children: u ? /* @__PURE__ */ N(ve, { children: [
|
|
400
|
+
/* @__PURE__ */ r(
|
|
401
|
+
"a",
|
|
402
|
+
{
|
|
403
|
+
className: "utrecht-breadcrumb-nav__link",
|
|
404
|
+
href: l.href ?? "#",
|
|
405
|
+
onClick: (h) => t == null ? void 0 : t({ item: l, event: h }),
|
|
406
|
+
children: l.label
|
|
407
|
+
}
|
|
408
|
+
),
|
|
409
|
+
/* @__PURE__ */ r("span", { className: "utrecht-breadcrumb-nav__separator", "aria-hidden": "true", children: "›" })
|
|
410
|
+
] }) : /* @__PURE__ */ r(
|
|
411
|
+
"span",
|
|
412
|
+
{
|
|
413
|
+
"aria-current": "page",
|
|
414
|
+
className: "utrecht-breadcrumb-nav__link utrecht-breadcrumb-nav__link--current",
|
|
415
|
+
children: l.label
|
|
416
|
+
}
|
|
417
|
+
) }, `${l.label ?? ""}-${o}`);
|
|
418
|
+
}) }) }) : null
|
|
419
|
+
);
|
|
420
|
+
Ye.displayName = "Breadcrumb";
|
|
421
|
+
const ze = s(
|
|
422
|
+
({ role: e = "group", className: a, children: t, ...i }, n) => /* @__PURE__ */ r("div", { ref: n, role: e, className: d("utrecht-button-group", a), ...i, children: t })
|
|
423
|
+
);
|
|
424
|
+
ze.displayName = "ButtonGroup";
|
|
425
|
+
const qe = {
|
|
426
|
+
"primary-action-button": "utrecht-button-link--primary-action",
|
|
427
|
+
"secondary-action-button": "utrecht-button-link--secondary-action",
|
|
428
|
+
"subtle-button": "utrecht-button-link--subtle"
|
|
429
|
+
}, Xe = s(
|
|
430
|
+
({ appearance: e, external: a, placeholder: t, rel: i, className: n, children: l, ...o }, c) => /* @__PURE__ */ r(
|
|
431
|
+
"a",
|
|
432
|
+
{
|
|
433
|
+
ref: c,
|
|
434
|
+
rel: a ? "external noopener noreferrer" : i,
|
|
435
|
+
"aria-disabled": t ? "true" : void 0,
|
|
436
|
+
className: d(
|
|
437
|
+
"utrecht-button-link",
|
|
438
|
+
"utrecht-button-link--html-a",
|
|
439
|
+
e && qe[e],
|
|
440
|
+
t && "utrecht-button-link--placeholder",
|
|
441
|
+
n
|
|
442
|
+
),
|
|
443
|
+
...o,
|
|
444
|
+
children: l
|
|
445
|
+
}
|
|
446
|
+
)
|
|
447
|
+
);
|
|
448
|
+
Xe.displayName = "ButtonLink";
|
|
449
|
+
const Ke = s(
|
|
450
|
+
({ invalid: e, indeterminate: a = !1, required: t, disabled: i, className: n, ...l }, o) => {
|
|
451
|
+
const c = M(null);
|
|
452
|
+
return ce(o, () => c.current, []), B(() => {
|
|
453
|
+
c.current && (c.current.indeterminate = a);
|
|
454
|
+
}, [a]), /* @__PURE__ */ r(
|
|
455
|
+
"input",
|
|
456
|
+
{
|
|
457
|
+
ref: c,
|
|
458
|
+
type: "checkbox",
|
|
459
|
+
required: t,
|
|
460
|
+
disabled: i,
|
|
461
|
+
"aria-checked": a ? "mixed" : void 0,
|
|
462
|
+
"aria-invalid": e ? "true" : void 0,
|
|
463
|
+
"aria-required": t ? "true" : void 0,
|
|
464
|
+
className: d(
|
|
465
|
+
"utrecht-checkbox",
|
|
466
|
+
"utrecht-checkbox--html-input",
|
|
467
|
+
"utrecht-checkbox--custom",
|
|
468
|
+
i && "utrecht-checkbox--disabled",
|
|
469
|
+
a && "utrecht-checkbox--indeterminate",
|
|
470
|
+
e && "utrecht-checkbox--invalid",
|
|
471
|
+
t && "utrecht-checkbox--required",
|
|
472
|
+
n
|
|
473
|
+
),
|
|
474
|
+
...l
|
|
475
|
+
}
|
|
476
|
+
);
|
|
477
|
+
}
|
|
478
|
+
);
|
|
479
|
+
Ke.displayName = "Checkbox";
|
|
480
|
+
function Je(e, a) {
|
|
481
|
+
const {
|
|
482
|
+
items: t,
|
|
483
|
+
placeholder: i,
|
|
484
|
+
disabled: n,
|
|
485
|
+
invalid: l,
|
|
486
|
+
required: o,
|
|
487
|
+
clearable: c,
|
|
488
|
+
"aria-label": u,
|
|
489
|
+
"aria-describedby": h,
|
|
490
|
+
className: f
|
|
491
|
+
} = e, x = V(), k = e.id ?? `tilburg-combobox-${x}`, p = `${k}-listbox`, g = (b) => `${k}-opt-${b}`, [m, L] = R(!1), [w, v] = R(-1), E = M(null), S = M(null);
|
|
492
|
+
B(() => {
|
|
493
|
+
typeof a == "function" ? a(E.current) : a && (a.current = E.current);
|
|
494
|
+
}, [a]);
|
|
495
|
+
const _ = W(() => e.multiple ? [...e.value] : e.value === null || e.value === void 0 ? [] : [e.value], [e.multiple, e.value]), I = A((b) => _.includes(b), [_]), D = A(() => {
|
|
496
|
+
n || (L(!0), v(-1));
|
|
497
|
+
}, [n]), C = A(() => {
|
|
498
|
+
L(!1), v(-1);
|
|
499
|
+
}, []), H = A(() => {
|
|
500
|
+
m ? C() : D();
|
|
501
|
+
}, [m, C, D]), P = A(
|
|
502
|
+
(b) => {
|
|
503
|
+
var T;
|
|
504
|
+
const y = t[b];
|
|
505
|
+
if (!(!y || y.disabled))
|
|
506
|
+
if (e.multiple) {
|
|
507
|
+
const ge = I(y.value) ? _.filter((fe) => fe !== y.value) : [..._, y.value];
|
|
508
|
+
e.onChange(ge);
|
|
509
|
+
} else
|
|
510
|
+
e.onChange(y.value), C(), (T = E.current) == null || T.focus();
|
|
511
|
+
},
|
|
512
|
+
[t, e, _, I, C]
|
|
513
|
+
), $ = A(
|
|
514
|
+
(b, y) => {
|
|
515
|
+
y == null || y.stopPropagation(), e.multiple && e.onChange(_.filter((T) => T !== b));
|
|
516
|
+
},
|
|
517
|
+
[e, _]
|
|
518
|
+
), O = A(
|
|
519
|
+
(b) => {
|
|
520
|
+
b == null || b.stopPropagation(), e.multiple ? e.onChange([]) : e.onChange(null);
|
|
521
|
+
},
|
|
522
|
+
[e]
|
|
523
|
+
), me = A(
|
|
524
|
+
(b) => {
|
|
525
|
+
if (!n)
|
|
526
|
+
switch (b.key) {
|
|
527
|
+
case "ArrowDown":
|
|
528
|
+
b.preventDefault(), m ? v((y) => Math.min(y + 1, t.length - 1)) : D();
|
|
529
|
+
break;
|
|
530
|
+
case "ArrowUp":
|
|
531
|
+
b.preventDefault(), m ? v((y) => Math.max(y - 1, 0)) : D();
|
|
532
|
+
break;
|
|
533
|
+
case "Home":
|
|
534
|
+
m && (b.preventDefault(), v(0));
|
|
535
|
+
break;
|
|
536
|
+
case "End":
|
|
537
|
+
m && (b.preventDefault(), v(t.length - 1));
|
|
538
|
+
break;
|
|
539
|
+
case "Enter":
|
|
540
|
+
m && w >= 0 && (b.preventDefault(), P(w));
|
|
541
|
+
break;
|
|
542
|
+
case "Escape":
|
|
543
|
+
m && (b.preventDefault(), C());
|
|
544
|
+
break;
|
|
545
|
+
case "Backspace":
|
|
546
|
+
e.multiple && (b.currentTarget.value ?? "") === "" && _.length > 0 && $(_[_.length - 1]);
|
|
547
|
+
break;
|
|
548
|
+
}
|
|
549
|
+
},
|
|
550
|
+
[n, m, D, t.length, w, C, e, _, $, P]
|
|
551
|
+
);
|
|
552
|
+
B(() => {
|
|
553
|
+
if (!m) return;
|
|
554
|
+
const b = (y) => {
|
|
555
|
+
var T;
|
|
556
|
+
(T = S.current) != null && T.contains(y.target) || C();
|
|
557
|
+
};
|
|
558
|
+
return document.addEventListener("mousedown", b), () => document.removeEventListener("mousedown", b);
|
|
559
|
+
}, [m, C]);
|
|
560
|
+
const be = W(
|
|
561
|
+
() => _.map((b) => t.find((y) => y.value === b)).filter((b) => !!b),
|
|
562
|
+
[_, t]
|
|
563
|
+
), pe = W(() => {
|
|
564
|
+
if (e.multiple) return "";
|
|
565
|
+
const b = t.find((y) => y.value === e.value);
|
|
566
|
+
return (b == null ? void 0 : b.label) ?? "";
|
|
567
|
+
}, [e, t]);
|
|
568
|
+
return /* @__PURE__ */ N("div", { ref: S, className: d("utrecht-combobox", e.multiple && "tilburg-combobox--multiple", f), children: [
|
|
569
|
+
/* @__PURE__ */ N("div", { className: "tilburg-combobox__value-container", onClick: H, children: [
|
|
570
|
+
e.multiple ? be.map((b) => /* @__PURE__ */ N("span", { className: "tilburg-combobox__chip", children: [
|
|
571
|
+
b.label,
|
|
572
|
+
/* @__PURE__ */ r(
|
|
573
|
+
"button",
|
|
574
|
+
{
|
|
575
|
+
type: "button",
|
|
576
|
+
className: "tilburg-combobox__chip-remove",
|
|
577
|
+
"aria-label": `Verwijder ${b.label}`,
|
|
578
|
+
disabled: n,
|
|
579
|
+
onClick: (y) => $(b.value, y),
|
|
580
|
+
children: "×"
|
|
581
|
+
}
|
|
582
|
+
)
|
|
583
|
+
] }, String(b.value))) : null,
|
|
584
|
+
/* @__PURE__ */ r(
|
|
585
|
+
"input",
|
|
586
|
+
{
|
|
587
|
+
ref: E,
|
|
588
|
+
id: k,
|
|
589
|
+
className: "tilburg-combobox__input",
|
|
590
|
+
type: "text",
|
|
591
|
+
role: "combobox",
|
|
592
|
+
readOnly: !0,
|
|
593
|
+
value: pe,
|
|
594
|
+
placeholder: e.multiple && _.length > 0 ? void 0 : i,
|
|
595
|
+
disabled: n,
|
|
596
|
+
"aria-label": u,
|
|
597
|
+
"aria-describedby": h,
|
|
598
|
+
"aria-expanded": m,
|
|
599
|
+
"aria-controls": p,
|
|
600
|
+
"aria-activedescendant": m && w >= 0 ? g(w) : void 0,
|
|
601
|
+
"aria-invalid": l ? "true" : void 0,
|
|
602
|
+
"aria-required": o ? "true" : void 0,
|
|
603
|
+
onKeyDown: me,
|
|
604
|
+
onChange: () => {
|
|
605
|
+
}
|
|
606
|
+
}
|
|
607
|
+
),
|
|
608
|
+
c && (e.multiple ? _.length > 0 : e.value !== null && e.value !== void 0) ? /* @__PURE__ */ r(
|
|
609
|
+
"button",
|
|
610
|
+
{
|
|
611
|
+
type: "button",
|
|
612
|
+
className: "tilburg-combobox__clear",
|
|
613
|
+
"aria-label": "Wis selectie",
|
|
614
|
+
disabled: n,
|
|
615
|
+
onClick: O,
|
|
616
|
+
children: /* @__PURE__ */ r(
|
|
617
|
+
"svg",
|
|
618
|
+
{
|
|
619
|
+
viewBox: "0 0 24 24",
|
|
620
|
+
fill: "none",
|
|
621
|
+
stroke: "currentColor",
|
|
622
|
+
strokeWidth: 2,
|
|
623
|
+
strokeLinecap: "round",
|
|
624
|
+
strokeLinejoin: "round",
|
|
625
|
+
"aria-hidden": "true",
|
|
626
|
+
children: /* @__PURE__ */ r("path", { d: "M18 6L6 18M6 6l12 12" })
|
|
627
|
+
}
|
|
628
|
+
)
|
|
629
|
+
}
|
|
630
|
+
) : null,
|
|
631
|
+
/* @__PURE__ */ r(
|
|
632
|
+
"button",
|
|
633
|
+
{
|
|
634
|
+
type: "button",
|
|
635
|
+
className: "tilburg-combobox__chevron",
|
|
636
|
+
"aria-label": m ? "Sluit opties" : "Toon opties",
|
|
637
|
+
tabIndex: -1,
|
|
638
|
+
disabled: n,
|
|
639
|
+
children: /* @__PURE__ */ r(
|
|
640
|
+
"svg",
|
|
641
|
+
{
|
|
642
|
+
viewBox: "0 0 24 24",
|
|
643
|
+
fill: "none",
|
|
644
|
+
stroke: "currentColor",
|
|
645
|
+
strokeWidth: 2,
|
|
646
|
+
strokeLinecap: "round",
|
|
647
|
+
strokeLinejoin: "round",
|
|
648
|
+
"aria-hidden": "true",
|
|
649
|
+
children: /* @__PURE__ */ r("path", { d: "M6 9l6 6 6-6" })
|
|
650
|
+
}
|
|
651
|
+
)
|
|
652
|
+
}
|
|
653
|
+
)
|
|
654
|
+
] }),
|
|
655
|
+
/* @__PURE__ */ r(
|
|
656
|
+
"ul",
|
|
657
|
+
{
|
|
658
|
+
id: p,
|
|
659
|
+
role: "listbox",
|
|
660
|
+
"aria-multiselectable": e.multiple ? !0 : void 0,
|
|
661
|
+
className: d(
|
|
662
|
+
"utrecht-listbox",
|
|
663
|
+
"utrecht-combobox__popover",
|
|
664
|
+
"utrecht-combobox__popover--block-end",
|
|
665
|
+
!m && "utrecht-combobox__popover--hidden"
|
|
666
|
+
),
|
|
667
|
+
children: t.map((b, y) => /* @__PURE__ */ r(
|
|
668
|
+
"li",
|
|
669
|
+
{
|
|
670
|
+
id: g(y),
|
|
671
|
+
role: "option",
|
|
672
|
+
className: "utrecht-listbox__option",
|
|
673
|
+
"data-active": w === y ? "true" : void 0,
|
|
674
|
+
"aria-selected": I(b.value),
|
|
675
|
+
"aria-disabled": b.disabled ? "true" : void 0,
|
|
676
|
+
onMouseEnter: () => v(y),
|
|
677
|
+
onMouseDown: (T) => {
|
|
678
|
+
T.preventDefault(), P(y);
|
|
679
|
+
},
|
|
680
|
+
children: b.label
|
|
681
|
+
},
|
|
682
|
+
String(b.value)
|
|
683
|
+
))
|
|
684
|
+
}
|
|
685
|
+
)
|
|
686
|
+
] });
|
|
687
|
+
}
|
|
688
|
+
const Qe = s(Je);
|
|
689
|
+
Qe.displayName = "Combobox";
|
|
690
|
+
const et = s(
|
|
691
|
+
({ large: e, className: a, children: t, ...i }, n) => /* @__PURE__ */ r("dl", { ref: n, className: d("tilburg-data-list", e && "tilburg-data-list--large", a), ...i, children: t })
|
|
692
|
+
);
|
|
693
|
+
et.displayName = "DataList";
|
|
694
|
+
const tt = s(
|
|
695
|
+
({ className: e, children: a, ...t }, i) => /* @__PURE__ */ r("div", { ref: i, className: d("tilburg-data-list__item", e), ...t, children: a })
|
|
696
|
+
);
|
|
697
|
+
tt.displayName = "DataListItem";
|
|
698
|
+
const at = s(
|
|
699
|
+
({ className: e, children: a, ...t }, i) => /* @__PURE__ */ r("dt", { ref: i, className: d("tilburg-data-list__key", e), ...t, children: a })
|
|
700
|
+
);
|
|
701
|
+
at.displayName = "DataListKey";
|
|
702
|
+
const rt = s(
|
|
703
|
+
({ className: e, children: a, ...t }, i) => /* @__PURE__ */ r("dd", { ref: i, className: d("tilburg-data-list__value", e), ...t, children: a })
|
|
704
|
+
);
|
|
705
|
+
rt.displayName = "DataListValue";
|
|
706
|
+
const it = s(
|
|
707
|
+
({ className: e, children: a, ...t }, i) => /* @__PURE__ */ r("div", { ref: i, className: d("utrecht-document", e), ...t, children: a })
|
|
708
|
+
);
|
|
709
|
+
it.displayName = "Document";
|
|
710
|
+
const nt = s(
|
|
711
|
+
({ invalid: e, disabled: a, className: t, children: i, ...n }, l) => /* @__PURE__ */ r(
|
|
712
|
+
"fieldset",
|
|
713
|
+
{
|
|
714
|
+
ref: l,
|
|
715
|
+
disabled: a,
|
|
716
|
+
"aria-invalid": e ? "true" : void 0,
|
|
717
|
+
className: d(
|
|
718
|
+
"utrecht-fieldset",
|
|
719
|
+
a && "utrecht-fieldset--disabled",
|
|
720
|
+
e && "utrecht-fieldset--invalid",
|
|
721
|
+
t
|
|
722
|
+
),
|
|
723
|
+
...n,
|
|
724
|
+
children: i
|
|
725
|
+
}
|
|
726
|
+
)
|
|
727
|
+
);
|
|
728
|
+
nt.displayName = "Fieldset";
|
|
729
|
+
const lt = s(
|
|
730
|
+
({ invalid: e, warning: a, type: t, className: i, children: n, ...l }, o) => /* @__PURE__ */ r(
|
|
731
|
+
"div",
|
|
732
|
+
{
|
|
733
|
+
ref: o,
|
|
734
|
+
className: d(
|
|
735
|
+
"utrecht-form-field",
|
|
736
|
+
t && `utrecht-form-field--${t}`,
|
|
737
|
+
e && "utrecht-form-field--invalid",
|
|
738
|
+
a && "tilburg-warning",
|
|
739
|
+
i
|
|
740
|
+
),
|
|
741
|
+
...l,
|
|
742
|
+
children: n
|
|
743
|
+
}
|
|
744
|
+
)
|
|
745
|
+
);
|
|
746
|
+
lt.displayName = "FormField";
|
|
747
|
+
const ot = s(
|
|
748
|
+
({ invalid: e, valid: a, warning: t, className: i, children: n, ...l }, o) => /* @__PURE__ */ r(
|
|
749
|
+
"div",
|
|
750
|
+
{
|
|
751
|
+
ref: o,
|
|
752
|
+
role: e ? "alert" : void 0,
|
|
753
|
+
className: d(
|
|
754
|
+
"utrecht-form-field-description",
|
|
755
|
+
e && "utrecht-form-field-description--invalid",
|
|
756
|
+
a && "utrecht-form-field-description--valid",
|
|
757
|
+
t && "utrecht-form-field-description--warning",
|
|
758
|
+
i
|
|
759
|
+
),
|
|
760
|
+
...l,
|
|
761
|
+
children: n
|
|
762
|
+
}
|
|
763
|
+
)
|
|
764
|
+
);
|
|
765
|
+
ot.displayName = "FormFieldDescription";
|
|
766
|
+
const ct = s(
|
|
767
|
+
({ type: e, checked: a, disabled: t, className: i, children: n, ...l }, o) => /* @__PURE__ */ r(
|
|
768
|
+
"label",
|
|
769
|
+
{
|
|
770
|
+
ref: o,
|
|
771
|
+
className: d(
|
|
772
|
+
"utrecht-form-label",
|
|
773
|
+
e && `utrecht-form-label--${e}`,
|
|
774
|
+
a && "utrecht-form-label--checked",
|
|
775
|
+
t && "utrecht-form-label--disabled",
|
|
776
|
+
i
|
|
777
|
+
),
|
|
778
|
+
...l,
|
|
779
|
+
children: n
|
|
780
|
+
}
|
|
781
|
+
)
|
|
782
|
+
);
|
|
783
|
+
ct.displayName = "FormLabel";
|
|
784
|
+
const st = s(
|
|
785
|
+
({ className: e, children: a, ...t }, i) => /* @__PURE__ */ r("div", { ref: i, className: d("utrecht-html-content", e), ...t, children: a })
|
|
786
|
+
);
|
|
787
|
+
st.displayName = "HtmlContent";
|
|
788
|
+
const dt = [
|
|
789
|
+
{ code: "NL", label: "NL" },
|
|
790
|
+
{ code: "EN", label: "EN" }
|
|
791
|
+
], ut = s(
|
|
792
|
+
({
|
|
793
|
+
options: e = dt,
|
|
794
|
+
active: a = "NL",
|
|
795
|
+
onToggle: t,
|
|
796
|
+
onClick: i,
|
|
797
|
+
onKeyDown: n,
|
|
798
|
+
"aria-label": l = "Switch language",
|
|
799
|
+
className: o,
|
|
800
|
+
...c
|
|
801
|
+
}, u) => {
|
|
802
|
+
const h = () => {
|
|
803
|
+
var m;
|
|
804
|
+
if (!e.length || !t)
|
|
805
|
+
return;
|
|
806
|
+
const g = (e.findIndex((L) => L.code === a) + 1) % e.length;
|
|
807
|
+
t(((m = e[g]) == null ? void 0 : m.code) ?? e[0].code);
|
|
808
|
+
}, f = (p) => {
|
|
809
|
+
i == null || i(p), !p.defaultPrevented && h();
|
|
810
|
+
}, x = (p) => {
|
|
811
|
+
n == null || n(p), !p.defaultPrevented && (p.key === "Enter" || p.key === " ") && (p.preventDefault(), h());
|
|
812
|
+
}, k = e.length > 0 && e[e.length - 1].code === a;
|
|
813
|
+
return /* @__PURE__ */ r(
|
|
814
|
+
"button",
|
|
815
|
+
{
|
|
816
|
+
ref: u,
|
|
817
|
+
type: "button",
|
|
818
|
+
role: "switch",
|
|
819
|
+
"aria-label": l,
|
|
820
|
+
"aria-checked": k ? "true" : "false",
|
|
821
|
+
onClick: f,
|
|
822
|
+
onKeyDown: x,
|
|
823
|
+
className: d(
|
|
824
|
+
"tilburg-language-toggle",
|
|
825
|
+
"utrecht-button",
|
|
826
|
+
"utrecht-button--html-button",
|
|
827
|
+
"utrecht-button--secondary-action",
|
|
828
|
+
o
|
|
829
|
+
),
|
|
830
|
+
...c,
|
|
831
|
+
children: e.map((p) => /* @__PURE__ */ r(
|
|
832
|
+
"span",
|
|
833
|
+
{
|
|
834
|
+
className: d(
|
|
835
|
+
"tilburg-language-toggle__option",
|
|
836
|
+
p.code === a && "tilburg-language-toggle__option--active"
|
|
837
|
+
),
|
|
838
|
+
children: p.label
|
|
839
|
+
},
|
|
840
|
+
p.code
|
|
841
|
+
))
|
|
842
|
+
}
|
|
843
|
+
);
|
|
844
|
+
}
|
|
845
|
+
);
|
|
846
|
+
ut.displayName = "LanguageToggle";
|
|
847
|
+
const ht = s(
|
|
848
|
+
({ external: e, rel: a, current: t, className: i, children: n, ...l }, o) => /* @__PURE__ */ r(
|
|
849
|
+
"a",
|
|
850
|
+
{
|
|
851
|
+
ref: o,
|
|
852
|
+
rel: e ? "external noopener noreferrer" : a,
|
|
853
|
+
"aria-current": t === void 0 ? void 0 : t,
|
|
854
|
+
className: d("utrecht-link", "utrecht-link--html-a", i),
|
|
855
|
+
...l,
|
|
856
|
+
children: n
|
|
857
|
+
}
|
|
858
|
+
)
|
|
859
|
+
);
|
|
860
|
+
ht.displayName = "Link";
|
|
861
|
+
const mt = s(
|
|
862
|
+
({ visible: e = !1, title: a, message: t, delayMs: i = 1e3, "aria-label": n, ...l }, o) => {
|
|
863
|
+
const [c, u] = R(!1), h = M(void 0);
|
|
864
|
+
return B(() => (h.current && (clearTimeout(h.current), h.current = void 0), e ? i <= 0 ? u(!0) : h.current = setTimeout(() => u(!0), i) : u(!1), () => {
|
|
865
|
+
h.current && clearTimeout(h.current);
|
|
866
|
+
}), [e, i]), c ? /* @__PURE__ */ r(
|
|
867
|
+
"div",
|
|
868
|
+
{
|
|
869
|
+
ref: o,
|
|
870
|
+
className: "tilburg-loading-spinner__overlay",
|
|
871
|
+
"aria-busy": "true",
|
|
872
|
+
"aria-label": n ?? void 0,
|
|
873
|
+
...l,
|
|
874
|
+
children: /* @__PURE__ */ r("div", { className: "tilburg-loading-spinner__panel", children: /* @__PURE__ */ N("div", { className: "tilburg-loading-spinner__content", role: "status", children: [
|
|
875
|
+
a && /* @__PURE__ */ r("span", { className: "tilburg-loading-spinner__title", children: a }),
|
|
876
|
+
/* @__PURE__ */ r("div", { children: /* @__PURE__ */ N(
|
|
877
|
+
"svg",
|
|
878
|
+
{
|
|
879
|
+
"aria-hidden": "true",
|
|
880
|
+
className: "tilburg-loading-spinner__svg",
|
|
881
|
+
viewBox: "0 0 100 101",
|
|
882
|
+
fill: "none",
|
|
883
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
884
|
+
children: [
|
|
885
|
+
/* @__PURE__ */ r(
|
|
886
|
+
"path",
|
|
887
|
+
{
|
|
888
|
+
d: "M100 50.5908C100 78.2051 77.6142 100.591 50 100.591C22.3858 100.591 0 78.2051 0 50.5908C0 22.9766 22.3858 0.59082 50 0.59082C77.6142 0.59082 100 22.9766 100 50.5908ZM9.08144 50.5908C9.08144 73.1895 27.4013 91.5094 50 91.5094C72.5987 91.5094 90.9186 73.1895 90.9186 50.5908C90.9186 27.9921 72.5987 9.67226 50 9.67226C27.4013 9.67226 9.08144 27.9921 9.08144 50.5908Z",
|
|
889
|
+
fill: "currentColor"
|
|
890
|
+
}
|
|
891
|
+
),
|
|
892
|
+
/* @__PURE__ */ r(
|
|
893
|
+
"path",
|
|
894
|
+
{
|
|
895
|
+
d: "M93.9676 39.0409C96.393 38.4038 97.8624 35.9116 97.0079 33.5539C95.2932 28.8227 92.871 24.3692 89.8167 20.348C85.8452 15.1192 80.8826 10.7238 75.2124 7.41289C69.5422 4.10194 63.2754 1.94025 56.7698 1.05124C51.7666 0.367541 46.6976 0.446843 41.7345 1.27873C39.2613 1.69328 37.813 4.19778 38.4501 6.62326C39.0873 9.04874 41.5694 10.4717 44.0505 10.1071C47.8511 9.54855 51.7191 9.52689 55.5402 10.0491C60.8642 10.7766 65.9928 12.5457 70.6331 15.2552C75.2735 17.9648 79.3347 21.5619 82.5849 25.841C84.9175 28.9121 86.7997 32.2913 88.1811 35.8758C89.083 38.2158 91.5421 39.6781 93.9676 39.0409Z",
|
|
896
|
+
fill: "currentFill"
|
|
897
|
+
}
|
|
898
|
+
)
|
|
899
|
+
]
|
|
900
|
+
}
|
|
901
|
+
) }),
|
|
902
|
+
t && /* @__PURE__ */ r("span", { className: "tilburg-loading-spinner__message", children: t })
|
|
903
|
+
] }) })
|
|
904
|
+
}
|
|
905
|
+
) : null;
|
|
906
|
+
}
|
|
907
|
+
);
|
|
908
|
+
mt.displayName = "LoadingSpinner";
|
|
909
|
+
const bt = s(
|
|
910
|
+
({ byLetter: e, className: a, children: t, ...i }, n) => /* @__PURE__ */ r(
|
|
911
|
+
"ol",
|
|
912
|
+
{
|
|
913
|
+
ref: n,
|
|
914
|
+
className: d(
|
|
915
|
+
"utrecht-ordered-list",
|
|
916
|
+
"utrecht-ordered-list--html-ol",
|
|
917
|
+
"tilburg-ordered-list",
|
|
918
|
+
e && "tilburg-ordered-list--by-letter",
|
|
919
|
+
a
|
|
920
|
+
),
|
|
921
|
+
...i,
|
|
922
|
+
children: t
|
|
923
|
+
}
|
|
924
|
+
)
|
|
925
|
+
);
|
|
926
|
+
bt.displayName = "OrderedList";
|
|
927
|
+
const pt = s(
|
|
928
|
+
({ className: e, children: a, ...t }, i) => /* @__PURE__ */ r("div", { ref: i, className: d("utrecht-page", e), ...t, children: a })
|
|
929
|
+
);
|
|
930
|
+
pt.displayName = "Page";
|
|
931
|
+
const gt = s(
|
|
932
|
+
({ className: e, children: a, ...t }, i) => /* @__PURE__ */ r("main", { ref: i, className: d("utrecht-page-content", e), ...t, children: a })
|
|
933
|
+
);
|
|
934
|
+
gt.displayName = "PageContent";
|
|
935
|
+
const ft = s(
|
|
936
|
+
({ links: e = [], primaryLink: a, className: t, children: i, ...n }, l) => /* @__PURE__ */ r("footer", { ref: l, className: d("tilburg-page-footer", t), ...n, children: /* @__PURE__ */ N("div", { className: "tilburg-page-footer__container", children: [
|
|
937
|
+
i,
|
|
938
|
+
a && /* @__PURE__ */ r("ul", { className: "tilburg-page-footer__primary", children: /* @__PURE__ */ r("li", { children: /* @__PURE__ */ r("a", { className: "tilburg-page-footer__primary-link", href: a.href, children: a.label }) }) }),
|
|
939
|
+
e.length > 0 && /* @__PURE__ */ r("ul", { className: "tilburg-page-footer__list", children: e.map((o) => /* @__PURE__ */ r("li", { children: /* @__PURE__ */ r("a", { className: "tilburg-page-footer__link", href: o.href, children: o.label }) }, `${o.label}|${o.href}`)) })
|
|
940
|
+
] }) })
|
|
941
|
+
);
|
|
942
|
+
ft.displayName = "PageFooter";
|
|
943
|
+
const vt = "Gemeente Tilburg", _t = s(
|
|
944
|
+
({
|
|
945
|
+
logoSrc: e,
|
|
946
|
+
logoAlt: a = "",
|
|
947
|
+
title: t,
|
|
948
|
+
titleHref: i = "/",
|
|
949
|
+
className: n,
|
|
950
|
+
children: l,
|
|
951
|
+
...o
|
|
952
|
+
}, c) => {
|
|
953
|
+
const u = _e.count(l) > 0;
|
|
954
|
+
return /* @__PURE__ */ r("header", { ref: c, className: d("tilburg-page-header", n), ...o, children: /* @__PURE__ */ N("div", { className: "tilburg-page-header__container", children: [
|
|
955
|
+
(e || t) && /* @__PURE__ */ N("a", { className: "tilburg-page-header__brand", href: i ?? "/", children: [
|
|
956
|
+
e && /* @__PURE__ */ r(
|
|
957
|
+
"img",
|
|
958
|
+
{
|
|
959
|
+
className: "tilburg-page-header__logo",
|
|
960
|
+
src: e,
|
|
961
|
+
alt: a || (t ? "" : vt)
|
|
962
|
+
}
|
|
963
|
+
),
|
|
964
|
+
t && /* @__PURE__ */ r("span", { className: "tilburg-page-header__title", children: t })
|
|
965
|
+
] }),
|
|
966
|
+
u && /* @__PURE__ */ r("div", { className: "tilburg-page-header__actions", children: l })
|
|
967
|
+
] }) });
|
|
968
|
+
}
|
|
969
|
+
);
|
|
970
|
+
_t.displayName = "PageHeader";
|
|
971
|
+
const ee = (e) => /* @__PURE__ */ r(
|
|
972
|
+
"svg",
|
|
973
|
+
{
|
|
974
|
+
className: "tilburg-pagination__icon",
|
|
975
|
+
"aria-hidden": "true",
|
|
976
|
+
viewBox: "0 0 24 24",
|
|
977
|
+
fill: "none",
|
|
978
|
+
stroke: "currentColor",
|
|
979
|
+
strokeWidth: "2",
|
|
980
|
+
strokeLinecap: "round",
|
|
981
|
+
strokeLinejoin: "round",
|
|
982
|
+
children: /* @__PURE__ */ r("polyline", { points: e })
|
|
983
|
+
}
|
|
984
|
+
), te = (e, a) => /* @__PURE__ */ N(
|
|
985
|
+
"svg",
|
|
986
|
+
{
|
|
987
|
+
className: "tilburg-pagination__icon",
|
|
988
|
+
"aria-hidden": "true",
|
|
989
|
+
viewBox: "0 0 24 24",
|
|
990
|
+
fill: "none",
|
|
991
|
+
stroke: "currentColor",
|
|
992
|
+
strokeWidth: "2",
|
|
993
|
+
strokeLinecap: "round",
|
|
994
|
+
strokeLinejoin: "round",
|
|
995
|
+
children: [
|
|
996
|
+
/* @__PURE__ */ r("polyline", { points: e }),
|
|
997
|
+
/* @__PURE__ */ r("polyline", { points: a })
|
|
998
|
+
]
|
|
999
|
+
}
|
|
1000
|
+
), Nt = (e, a) => {
|
|
1001
|
+
if (e <= 0) return [];
|
|
1002
|
+
if (e <= 7) return Array.from({ length: e }, (l, o) => ({ kind: "page", value: o + 1 }));
|
|
1003
|
+
const t = [{ kind: "page", value: 1 }], i = Math.max(2, a - 1), n = Math.min(e - 1, a + 1);
|
|
1004
|
+
i > 2 && t.push({ kind: "ellipsis", key: "lead" });
|
|
1005
|
+
for (let l = i; l <= n; l += 1) t.push({ kind: "page", value: l });
|
|
1006
|
+
return n < e - 1 && t.push({ kind: "ellipsis", key: "trail" }), t.push({ kind: "page", value: e }), t;
|
|
1007
|
+
}, yt = s(
|
|
1008
|
+
({
|
|
1009
|
+
ariaLabel: e = "Paginering",
|
|
1010
|
+
feedback: a,
|
|
1011
|
+
range: t,
|
|
1012
|
+
pageCount: i,
|
|
1013
|
+
currentPage: n,
|
|
1014
|
+
firstDisabled: l = !1,
|
|
1015
|
+
previousDisabled: o = !1,
|
|
1016
|
+
nextDisabled: c = !1,
|
|
1017
|
+
lastDisabled: u = !1,
|
|
1018
|
+
firstLabel: h = "Eerste pagina",
|
|
1019
|
+
previousLabel: f = "Vorige pagina",
|
|
1020
|
+
nextLabel: x = "Volgende pagina",
|
|
1021
|
+
lastLabel: k = "Laatste pagina",
|
|
1022
|
+
pageLabel: p = (v) => `Pagina ${v}`,
|
|
1023
|
+
onNavigate: g,
|
|
1024
|
+
className: m,
|
|
1025
|
+
...L
|
|
1026
|
+
}, w) => {
|
|
1027
|
+
const v = Nt(i ?? 0, n ?? 1), E = (_) => () => g == null ? void 0 : g({ step: _ }), S = (_) => {
|
|
1028
|
+
_ !== n && (g == null || g({ step: "page", page: _ }));
|
|
1029
|
+
};
|
|
1030
|
+
return /* @__PURE__ */ N("nav", { ref: w, className: d("tilburg-pagination", m), "aria-label": e, ...L, children: [
|
|
1031
|
+
a && /* @__PURE__ */ r("div", { className: "tilburg-pagination__feedback", children: a }),
|
|
1032
|
+
/* @__PURE__ */ N("div", { className: "tilburg-pagination__controls", children: [
|
|
1033
|
+
/* @__PURE__ */ r(
|
|
1034
|
+
"button",
|
|
1035
|
+
{
|
|
1036
|
+
type: "button",
|
|
1037
|
+
className: "tilburg-pagination__button",
|
|
1038
|
+
disabled: l,
|
|
1039
|
+
"aria-label": h,
|
|
1040
|
+
onClick: E("first"),
|
|
1041
|
+
children: te("11 17 6 12 11 7", "18 17 13 12 18 7")
|
|
1042
|
+
}
|
|
1043
|
+
),
|
|
1044
|
+
/* @__PURE__ */ r(
|
|
1045
|
+
"button",
|
|
1046
|
+
{
|
|
1047
|
+
type: "button",
|
|
1048
|
+
className: "tilburg-pagination__button",
|
|
1049
|
+
disabled: o,
|
|
1050
|
+
"aria-label": f,
|
|
1051
|
+
onClick: E("previous"),
|
|
1052
|
+
children: ee("15 18 9 12 15 6")
|
|
1053
|
+
}
|
|
1054
|
+
),
|
|
1055
|
+
v.length > 0 ? /* @__PURE__ */ r("ul", { className: "tilburg-pagination__pages", children: v.map(
|
|
1056
|
+
(_, I) => _.kind === "ellipsis" ? /* @__PURE__ */ r("li", { children: /* @__PURE__ */ r("span", { className: "tilburg-pagination__ellipsis", "aria-hidden": "true", children: "…" }) }, `e-${_.key}-${I}`) : /* @__PURE__ */ r("li", { children: /* @__PURE__ */ r(
|
|
1057
|
+
"button",
|
|
1058
|
+
{
|
|
1059
|
+
type: "button",
|
|
1060
|
+
className: "tilburg-pagination__page" + (_.value === n ? " tilburg-pagination__page--current" : ""),
|
|
1061
|
+
"aria-current": _.value === n ? "page" : void 0,
|
|
1062
|
+
"aria-label": p(_.value),
|
|
1063
|
+
disabled: _.value === n,
|
|
1064
|
+
onClick: () => S(_.value),
|
|
1065
|
+
children: _.value
|
|
1066
|
+
}
|
|
1067
|
+
) }, `p-${_.value}`)
|
|
1068
|
+
) }) : t && /* @__PURE__ */ r("div", { className: "tilburg-pagination__range", children: t }),
|
|
1069
|
+
/* @__PURE__ */ r(
|
|
1070
|
+
"button",
|
|
1071
|
+
{
|
|
1072
|
+
type: "button",
|
|
1073
|
+
className: "tilburg-pagination__button",
|
|
1074
|
+
disabled: c,
|
|
1075
|
+
"aria-label": x,
|
|
1076
|
+
onClick: E("next"),
|
|
1077
|
+
children: ee("9 18 15 12 9 6")
|
|
1078
|
+
}
|
|
1079
|
+
),
|
|
1080
|
+
/* @__PURE__ */ r(
|
|
1081
|
+
"button",
|
|
1082
|
+
{
|
|
1083
|
+
type: "button",
|
|
1084
|
+
className: "tilburg-pagination__button",
|
|
1085
|
+
disabled: u,
|
|
1086
|
+
"aria-label": k,
|
|
1087
|
+
onClick: E("last"),
|
|
1088
|
+
children: te("13 17 18 12 13 7", "6 17 11 12 6 7")
|
|
1089
|
+
}
|
|
1090
|
+
)
|
|
1091
|
+
] })
|
|
1092
|
+
] });
|
|
1093
|
+
}
|
|
1094
|
+
);
|
|
1095
|
+
yt.displayName = "Pagination";
|
|
1096
|
+
const ue = s(
|
|
1097
|
+
({ invalid: e, required: a, disabled: t, readOnly: i, type: n = "text", className: l, ...o }, c) => /* @__PURE__ */ r(
|
|
1098
|
+
"input",
|
|
1099
|
+
{
|
|
1100
|
+
ref: c,
|
|
1101
|
+
type: n,
|
|
1102
|
+
required: a,
|
|
1103
|
+
disabled: t,
|
|
1104
|
+
readOnly: i,
|
|
1105
|
+
"aria-invalid": e ? "true" : void 0,
|
|
1106
|
+
"aria-required": a ? "true" : void 0,
|
|
1107
|
+
className: d(
|
|
1108
|
+
"utrecht-textbox",
|
|
1109
|
+
"utrecht-textbox--html-input",
|
|
1110
|
+
t && "utrecht-textbox--disabled",
|
|
1111
|
+
e && "utrecht-textbox--invalid",
|
|
1112
|
+
i && "utrecht-textbox--read-only",
|
|
1113
|
+
a && "utrecht-textbox--required",
|
|
1114
|
+
l
|
|
1115
|
+
),
|
|
1116
|
+
...o
|
|
1117
|
+
}
|
|
1118
|
+
)
|
|
1119
|
+
);
|
|
1120
|
+
ue.displayName = "Textbox";
|
|
1121
|
+
const xt = () => /* @__PURE__ */ N(
|
|
1122
|
+
"svg",
|
|
1123
|
+
{
|
|
1124
|
+
className: "tilburg-password-input__icon tilburg-password-input__icon--show",
|
|
1125
|
+
"aria-hidden": "true",
|
|
1126
|
+
viewBox: "0 0 24 24",
|
|
1127
|
+
fill: "none",
|
|
1128
|
+
stroke: "currentColor",
|
|
1129
|
+
strokeWidth: 2,
|
|
1130
|
+
strokeLinecap: "round",
|
|
1131
|
+
strokeLinejoin: "round",
|
|
1132
|
+
children: [
|
|
1133
|
+
/* @__PURE__ */ r("path", { d: "M1 12s4-8 11-8 11 8 11 8-4 8-11 8-11-8-11-8z" }),
|
|
1134
|
+
/* @__PURE__ */ r("circle", { cx: "12", cy: "12", r: "3" })
|
|
1135
|
+
]
|
|
1136
|
+
}
|
|
1137
|
+
), kt = () => /* @__PURE__ */ N(
|
|
1138
|
+
"svg",
|
|
1139
|
+
{
|
|
1140
|
+
className: "tilburg-password-input__icon tilburg-password-input__icon--hide",
|
|
1141
|
+
"aria-hidden": "true",
|
|
1142
|
+
viewBox: "0 0 24 24",
|
|
1143
|
+
fill: "none",
|
|
1144
|
+
stroke: "currentColor",
|
|
1145
|
+
strokeWidth: 2,
|
|
1146
|
+
strokeLinecap: "round",
|
|
1147
|
+
strokeLinejoin: "round",
|
|
1148
|
+
children: [
|
|
1149
|
+
/* @__PURE__ */ r("path", { d: "M17.94 17.94A10 10 0 0 1 12 20c-7 0-11-8-11-8a18.5 18.5 0 0 1 5.06-5.94M9.9 4.24A9.1 9.1 0 0 1 12 4c7 0 11 8 11 8a18.5 18.5 0 0 1-2.16 3.19M14.12 14.12a3 3 0 1 1-4.24-4.24" }),
|
|
1150
|
+
/* @__PURE__ */ r("path", { d: "M1 1l22 22" })
|
|
1151
|
+
]
|
|
1152
|
+
}
|
|
1153
|
+
), Lt = s(
|
|
1154
|
+
({
|
|
1155
|
+
id: e,
|
|
1156
|
+
toggleLabel: a = "Wachtwoord tonen",
|
|
1157
|
+
statusShown: t = "Wachtwoord is zichtbaar.",
|
|
1158
|
+
statusHidden: i = "Wachtwoord is verborgen.",
|
|
1159
|
+
wrapperClassName: n,
|
|
1160
|
+
disabled: l,
|
|
1161
|
+
...o
|
|
1162
|
+
}, c) => {
|
|
1163
|
+
const u = V(), h = e ?? u, [f, x] = R(!1), [k, p] = R(""), g = () => {
|
|
1164
|
+
x(!f), p(f ? i : t);
|
|
1165
|
+
};
|
|
1166
|
+
return /* @__PURE__ */ N("div", { className: d("tilburg-password-input", n), children: [
|
|
1167
|
+
/* @__PURE__ */ r(ue, { ref: c, id: h, type: f ? "text" : "password", disabled: l, ...o }),
|
|
1168
|
+
/* @__PURE__ */ N(
|
|
1169
|
+
"button",
|
|
1170
|
+
{
|
|
1171
|
+
type: "button",
|
|
1172
|
+
className: "tilburg-password-input__toggle",
|
|
1173
|
+
"aria-pressed": f,
|
|
1174
|
+
"aria-controls": h,
|
|
1175
|
+
"aria-label": a,
|
|
1176
|
+
disabled: l,
|
|
1177
|
+
onClick: g,
|
|
1178
|
+
children: [
|
|
1179
|
+
/* @__PURE__ */ r(xt, {}),
|
|
1180
|
+
/* @__PURE__ */ r(kt, {})
|
|
1181
|
+
]
|
|
1182
|
+
}
|
|
1183
|
+
),
|
|
1184
|
+
/* @__PURE__ */ r("span", { className: "tilburg-password-input__status", "aria-live": "polite", children: k })
|
|
1185
|
+
] });
|
|
1186
|
+
}
|
|
1187
|
+
);
|
|
1188
|
+
Lt.displayName = "PasswordInput";
|
|
1189
|
+
const wt = s(
|
|
1190
|
+
({ lead: e, small: a, className: t, children: i, ...n }, l) => /* @__PURE__ */ r(
|
|
1191
|
+
"p",
|
|
1192
|
+
{
|
|
1193
|
+
ref: l,
|
|
1194
|
+
className: d(
|
|
1195
|
+
"utrecht-paragraph",
|
|
1196
|
+
e && "utrecht-paragraph--lead",
|
|
1197
|
+
a && "utrecht-paragraph--small",
|
|
1198
|
+
t
|
|
1199
|
+
),
|
|
1200
|
+
...n,
|
|
1201
|
+
children: i
|
|
1202
|
+
}
|
|
1203
|
+
)
|
|
1204
|
+
);
|
|
1205
|
+
wt.displayName = "Paragraph";
|
|
1206
|
+
const Ct = s(
|
|
1207
|
+
({
|
|
1208
|
+
value: e = 0,
|
|
1209
|
+
total: a = 0,
|
|
1210
|
+
label: t,
|
|
1211
|
+
title: i,
|
|
1212
|
+
backLabel: n,
|
|
1213
|
+
showBack: l = !1,
|
|
1214
|
+
backIcon: o,
|
|
1215
|
+
onBackClick: c,
|
|
1216
|
+
"aria-label": u,
|
|
1217
|
+
...h
|
|
1218
|
+
}, f) => {
|
|
1219
|
+
const x = a <= 0 ? 0 : Math.max(0, Math.min(100, e / a * 100));
|
|
1220
|
+
return /* @__PURE__ */ N("div", { ref: f, ...h, children: [
|
|
1221
|
+
l && /* @__PURE__ */ N("a", { className: "tilburg-progress-bar__back utrecht-link utrecht-link--html-a", href: "#", onClick: (g) => {
|
|
1222
|
+
g.preventDefault(), c == null || c(g);
|
|
1223
|
+
}, children: [
|
|
1224
|
+
o === void 0 ? /* @__PURE__ */ r("span", { "aria-hidden": "true", children: "←" }) : o,
|
|
1225
|
+
/* @__PURE__ */ r("span", { className: "tilburg-progress-bar__back-label", children: n })
|
|
1226
|
+
] }),
|
|
1227
|
+
/* @__PURE__ */ N("div", { className: "tilburg-progress-bar__header", children: [
|
|
1228
|
+
i && /* @__PURE__ */ r("h2", { className: "tilburg-progress-bar__title tilburg-step-title", children: i }),
|
|
1229
|
+
t && /* @__PURE__ */ r("div", { className: "tilburg-progress-bar__label", children: t })
|
|
1230
|
+
] }),
|
|
1231
|
+
/* @__PURE__ */ r(
|
|
1232
|
+
"div",
|
|
1233
|
+
{
|
|
1234
|
+
className: "tilburg-progress-bar__track",
|
|
1235
|
+
role: "progressbar",
|
|
1236
|
+
"aria-label": u ?? i ?? "Voortgang",
|
|
1237
|
+
"aria-valuemin": 0,
|
|
1238
|
+
"aria-valuemax": 100,
|
|
1239
|
+
"aria-valuenow": Math.round(x),
|
|
1240
|
+
"aria-valuetext": t ?? void 0,
|
|
1241
|
+
children: /* @__PURE__ */ r("div", { className: "tilburg-progress-bar__indicator progress-bar-indicator", style: { width: `${x}%` } })
|
|
1242
|
+
}
|
|
1243
|
+
)
|
|
1244
|
+
] });
|
|
1245
|
+
}
|
|
1246
|
+
);
|
|
1247
|
+
Ct.displayName = "ProgressBar";
|
|
1248
|
+
const Et = s(
|
|
1249
|
+
({ invalid: e, required: a, disabled: t, className: i, ...n }, l) => /* @__PURE__ */ r(
|
|
1250
|
+
"input",
|
|
1251
|
+
{
|
|
1252
|
+
ref: l,
|
|
1253
|
+
type: "radio",
|
|
1254
|
+
required: a,
|
|
1255
|
+
disabled: t,
|
|
1256
|
+
"aria-invalid": e ? "true" : void 0,
|
|
1257
|
+
"aria-required": a ? "true" : void 0,
|
|
1258
|
+
className: d(
|
|
1259
|
+
"utrecht-radio-button",
|
|
1260
|
+
"utrecht-radio-button--html-input",
|
|
1261
|
+
t && "utrecht-radio-button--disabled",
|
|
1262
|
+
e && "utrecht-radio-button--invalid",
|
|
1263
|
+
a && "utrecht-radio-button--required",
|
|
1264
|
+
i
|
|
1265
|
+
),
|
|
1266
|
+
...n
|
|
1267
|
+
}
|
|
1268
|
+
)
|
|
1269
|
+
);
|
|
1270
|
+
Et.displayName = "RadioButton";
|
|
1271
|
+
const At = s(
|
|
1272
|
+
({ invalid: e, required: a, disabled: t, className: i, children: n, ...l }, o) => /* @__PURE__ */ r(
|
|
1273
|
+
"select",
|
|
1274
|
+
{
|
|
1275
|
+
ref: o,
|
|
1276
|
+
required: a,
|
|
1277
|
+
disabled: t,
|
|
1278
|
+
"aria-invalid": e ? "true" : void 0,
|
|
1279
|
+
"aria-required": a ? "true" : void 0,
|
|
1280
|
+
className: d(
|
|
1281
|
+
"utrecht-select",
|
|
1282
|
+
"utrecht-select--html-select",
|
|
1283
|
+
t && "utrecht-select--disabled",
|
|
1284
|
+
e && "utrecht-select--invalid",
|
|
1285
|
+
i
|
|
1286
|
+
),
|
|
1287
|
+
...l,
|
|
1288
|
+
children: n
|
|
1289
|
+
}
|
|
1290
|
+
)
|
|
1291
|
+
);
|
|
1292
|
+
At.displayName = "Select";
|
|
1293
|
+
const Tt = s(
|
|
1294
|
+
({ decorative: e, className: a, ...t }, i) => /* @__PURE__ */ r(
|
|
1295
|
+
"hr",
|
|
1296
|
+
{
|
|
1297
|
+
ref: i,
|
|
1298
|
+
"aria-hidden": e ? "true" : void 0,
|
|
1299
|
+
className: d("utrecht-separator", a),
|
|
1300
|
+
...t
|
|
1301
|
+
}
|
|
1302
|
+
)
|
|
1303
|
+
);
|
|
1304
|
+
Tt.displayName = "Separator";
|
|
1305
|
+
const St = s(
|
|
1306
|
+
({ visibility: e = "visible-on-focus", className: a, children: t, ...i }, n) => /* @__PURE__ */ r("a", { ref: n, className: d("utrecht-skip-link", `utrecht-skip-link--${e}`, a), ...i, children: t })
|
|
1307
|
+
);
|
|
1308
|
+
St.displayName = "SkipLink";
|
|
1309
|
+
const It = s(
|
|
1310
|
+
({ caption: e, className: a, children: t, ...i }, n) => /* @__PURE__ */ N("table", { ref: n, className: d("utrecht-table", a), ...i, children: [
|
|
1311
|
+
e && /* @__PURE__ */ r("caption", { className: "utrecht-table__caption", children: e }),
|
|
1312
|
+
t
|
|
1313
|
+
] })
|
|
1314
|
+
);
|
|
1315
|
+
It.displayName = "Table";
|
|
1316
|
+
const Mt = s(
|
|
1317
|
+
({ className: e, children: a, ...t }, i) => /* @__PURE__ */ r("tbody", { ref: i, className: d("utrecht-table__body", e), ...t, children: a })
|
|
1318
|
+
);
|
|
1319
|
+
Mt.displayName = "TableBody";
|
|
1320
|
+
const Dt = s(
|
|
1321
|
+
({ className: e, children: a, ...t }, i) => /* @__PURE__ */ r("caption", { ref: i, className: d("utrecht-table__caption", e), ...t, children: a })
|
|
1322
|
+
);
|
|
1323
|
+
Dt.displayName = "TableCaption";
|
|
1324
|
+
const Bt = s(
|
|
1325
|
+
({ className: e, children: a, ...t }, i) => /* @__PURE__ */ r("td", { ref: i, className: d("utrecht-table__cell", e), ...t, children: a })
|
|
1326
|
+
);
|
|
1327
|
+
Bt.displayName = "TableCell";
|
|
1328
|
+
const Ht = s(
|
|
1329
|
+
({ className: e, children: a, ...t }, i) => /* @__PURE__ */ r("tfoot", { ref: i, className: d("utrecht-table__footer", e), ...t, children: a })
|
|
1330
|
+
);
|
|
1331
|
+
Ht.displayName = "TableFooter";
|
|
1332
|
+
const Pt = s(
|
|
1333
|
+
({ className: e, children: a, ...t }, i) => /* @__PURE__ */ r("thead", { ref: i, className: d("utrecht-table__header", e), ...t, children: a })
|
|
1334
|
+
);
|
|
1335
|
+
Pt.displayName = "TableHeader";
|
|
1336
|
+
const Rt = s(
|
|
1337
|
+
({ className: e, children: a, ...t }, i) => /* @__PURE__ */ r("th", { ref: i, className: d("utrecht-table__header-cell", e), ...t, children: a })
|
|
1338
|
+
);
|
|
1339
|
+
Rt.displayName = "TableHeaderCell";
|
|
1340
|
+
const Ft = s(
|
|
1341
|
+
({ className: e, children: a, ...t }, i) => /* @__PURE__ */ r("tr", { ref: i, className: d("utrecht-table__row", e), ...t, children: a })
|
|
1342
|
+
);
|
|
1343
|
+
Ft.displayName = "TableRow";
|
|
1344
|
+
const $t = s(
|
|
1345
|
+
({ invalid: e, required: a, disabled: t, readOnly: i, className: n, ...l }, o) => /* @__PURE__ */ r(
|
|
1346
|
+
"textarea",
|
|
1347
|
+
{
|
|
1348
|
+
ref: o,
|
|
1349
|
+
required: a,
|
|
1350
|
+
disabled: t,
|
|
1351
|
+
readOnly: i,
|
|
1352
|
+
"aria-invalid": e ? "true" : void 0,
|
|
1353
|
+
"aria-required": a ? "true" : void 0,
|
|
1354
|
+
className: d(
|
|
1355
|
+
"utrecht-textarea",
|
|
1356
|
+
"utrecht-textarea--html-textarea",
|
|
1357
|
+
t && "utrecht-textarea--disabled",
|
|
1358
|
+
e && "utrecht-textarea--invalid",
|
|
1359
|
+
i && "utrecht-textarea--read-only",
|
|
1360
|
+
a && "utrecht-textarea--required",
|
|
1361
|
+
n
|
|
1362
|
+
),
|
|
1363
|
+
...l
|
|
1364
|
+
}
|
|
1365
|
+
)
|
|
1366
|
+
);
|
|
1367
|
+
$t.displayName = "Textarea";
|
|
1368
|
+
/* @license CC0-1.0 */
|
|
1369
|
+
const Ot = "data-tilburg-tooltip-enhance", ae = "data-tilburg-tooltip-enhanced", U = "tilburg-tooltip--open", Zt = "tilburg-tooltip--below", re = "data-tilburg-tooltip-placement", ie = "--_tilburg-tooltip-shift", Z = 8, ne = /^(auto|clip|hidden|scroll)$/, Gt = 150, Vt = 150, G = () => typeof matchMedia != "function" || !matchMedia("(hover: none)").matches;
|
|
1370
|
+
function Wt(e) {
|
|
1371
|
+
const a = document.documentElement, t = { top: 0, left: 0, right: a.clientWidth, bottom: a.clientHeight };
|
|
1372
|
+
for (let i = e.parentElement; i && i !== document.body; i = i.parentElement) {
|
|
1373
|
+
const { overflowX: n, overflowY: l } = getComputedStyle(i), o = ne.test(n), c = ne.test(l);
|
|
1374
|
+
if (!o && !c) continue;
|
|
1375
|
+
const u = i.getBoundingClientRect();
|
|
1376
|
+
c && (t.top = Math.max(t.top, u.top), t.bottom = Math.min(t.bottom, u.bottom)), o && (t.left = Math.max(t.left, u.left), t.right = Math.min(t.right, u.right));
|
|
1377
|
+
}
|
|
1378
|
+
return t;
|
|
1379
|
+
}
|
|
1380
|
+
function le(e) {
|
|
1381
|
+
const a = e.querySelector(".tilburg-tooltip__popup");
|
|
1382
|
+
if (!a || typeof getComputedStyle != "function") return;
|
|
1383
|
+
const t = Wt(e);
|
|
1384
|
+
if (t.right <= t.left || t.bottom <= t.top) return;
|
|
1385
|
+
a.style.removeProperty(ie);
|
|
1386
|
+
const i = e.classList.contains(Zt) ? "below" : "above", n = i === "above" ? "below" : "above", l = (h) => {
|
|
1387
|
+
e.setAttribute(re, h);
|
|
1388
|
+
const f = a.getBoundingClientRect();
|
|
1389
|
+
return Math.max(0, t.top - f.top) + Math.max(0, f.bottom - t.bottom);
|
|
1390
|
+
}, o = l(i);
|
|
1391
|
+
o > 0 && l(n) >= o && e.setAttribute(re, i);
|
|
1392
|
+
const c = a.getBoundingClientRect();
|
|
1393
|
+
let u = 0;
|
|
1394
|
+
c.left < t.left + Z ? u = t.left + Z - c.left : c.right > t.right - Z && (u = t.right - Z - c.right), u && a.style.setProperty(ie, `${Math.round(u)}px`);
|
|
1395
|
+
}
|
|
1396
|
+
function he(e) {
|
|
1397
|
+
let a, t;
|
|
1398
|
+
const i = () => {
|
|
1399
|
+
clearTimeout(a), clearTimeout(t);
|
|
1400
|
+
}, n = () => e.classList.contains(U), l = (m) => {
|
|
1401
|
+
m.key === "Escape" && h();
|
|
1402
|
+
}, o = (m) => {
|
|
1403
|
+
e.contains(m.target) || h();
|
|
1404
|
+
}, c = () => le(e);
|
|
1405
|
+
function u() {
|
|
1406
|
+
i(), !n() && (e.classList.add(U), le(e), document.addEventListener("keydown", l), document.addEventListener("scroll", c, { capture: !0, passive: !0 }), window.addEventListener("resize", c), G() || document.addEventListener("click", o));
|
|
1407
|
+
}
|
|
1408
|
+
function h() {
|
|
1409
|
+
i(), n() && (e.classList.remove(U), document.removeEventListener("keydown", l), document.removeEventListener("scroll", c, { capture: !0 }), window.removeEventListener("resize", c), document.removeEventListener("click", o));
|
|
1410
|
+
}
|
|
1411
|
+
const f = () => {
|
|
1412
|
+
G() && (clearTimeout(t), a = setTimeout(u, Gt));
|
|
1413
|
+
}, x = () => {
|
|
1414
|
+
G() && (clearTimeout(a), t = setTimeout(h, Vt));
|
|
1415
|
+
}, k = () => u(), p = (m) => {
|
|
1416
|
+
e.contains(m.relatedTarget) || h();
|
|
1417
|
+
}, g = (m) => {
|
|
1418
|
+
G() || m.target.closest(".tilburg-tooltip__popup") || (n() ? h() : u());
|
|
1419
|
+
};
|
|
1420
|
+
return e.addEventListener("mouseenter", f), e.addEventListener("mouseleave", x), e.addEventListener("focusin", k), e.addEventListener("focusout", p), e.addEventListener("click", g), () => {
|
|
1421
|
+
h(), e.removeEventListener("mouseenter", f), e.removeEventListener("mouseleave", x), e.removeEventListener("focusin", k), e.removeEventListener("focusout", p), e.removeEventListener("click", g);
|
|
1422
|
+
};
|
|
1423
|
+
}
|
|
1424
|
+
function oe(e = typeof document < "u" ? document : null) {
|
|
1425
|
+
e && e.querySelectorAll(`.tilburg-tooltip[${Ot}]:not([${ae}])`).forEach((a) => {
|
|
1426
|
+
a.setAttribute(ae, ""), he(a);
|
|
1427
|
+
});
|
|
1428
|
+
}
|
|
1429
|
+
typeof document < "u" && (document.readyState === "loading" ? document.addEventListener("DOMContentLoaded", () => oe()) : oe());
|
|
1430
|
+
const Ut = ({ content: e, placement: a = "above", className: t, children: i }) => {
|
|
1431
|
+
const n = M(null), l = V();
|
|
1432
|
+
B(() => n.current ? he(n.current) : void 0, []);
|
|
1433
|
+
const o = Ne(i) ? ye(i, {
|
|
1434
|
+
"aria-describedby": [i.props["aria-describedby"], l].filter(Boolean).join(" ")
|
|
1435
|
+
}) : i;
|
|
1436
|
+
return /* @__PURE__ */ N("span", { ref: n, className: d("tilburg-tooltip", a === "below" && "tilburg-tooltip--below", t), children: [
|
|
1437
|
+
o,
|
|
1438
|
+
/* @__PURE__ */ r("span", { className: "tilburg-tooltip__popup", id: l, role: "tooltip", children: e })
|
|
1439
|
+
] });
|
|
1440
|
+
};
|
|
1441
|
+
Ut.displayName = "Tooltip";
|
|
1442
|
+
const jt = s(
|
|
1443
|
+
({ className: e, children: a, ...t }, i) => /* @__PURE__ */ r(
|
|
1444
|
+
"ul",
|
|
1445
|
+
{
|
|
1446
|
+
ref: i,
|
|
1447
|
+
className: d("utrecht-unordered-list", "utrecht-unordered-list--html-ul", "tilburg-unordered-list", e),
|
|
1448
|
+
...t,
|
|
1449
|
+
children: a
|
|
1450
|
+
}
|
|
1451
|
+
)
|
|
1452
|
+
);
|
|
1453
|
+
jt.displayName = "UnorderedList";
|
|
1454
|
+
const Yt = s(
|
|
1455
|
+
({ className: e, children: a, ...t }, i) => /* @__PURE__ */ r("li", { ref: i, className: d("utrecht-unordered-list__item", e), ...t, children: a })
|
|
1456
|
+
);
|
|
1457
|
+
Yt.displayName = "UnorderedListItem";
|
|
1458
|
+
const zt = () => /* @__PURE__ */ r("svg", { "aria-hidden": "true", width: "20", height: "20", viewBox: "0 0 20 20", fill: "currentColor", children: /* @__PURE__ */ r("path", { d: "M10 1a9 9 0 1 0 0 18 9 9 0 0 0 0-18Zm1 13H9v-2h2v2Zm0-4H9V5h2v5Z" }) }), qt = () => /* @__PURE__ */ r("svg", { "aria-hidden": "true", width: "20", height: "20", viewBox: "0 0 20 20", fill: "currentColor", children: /* @__PURE__ */ r("path", { d: "M10 1 1 19h18L10 1Zm0 5 1 7h-2l1-7Zm0 9a1 1 0 1 1 0 2 1 1 0 0 1 0-2Z" }) }), Xt = {
|
|
1459
|
+
error: /* @__PURE__ */ r(zt, {}),
|
|
1460
|
+
warning: /* @__PURE__ */ r(qt, {})
|
|
1461
|
+
}, Kt = {
|
|
1462
|
+
assertive: "alert",
|
|
1463
|
+
polite: "status",
|
|
1464
|
+
off: void 0
|
|
1465
|
+
}, Jt = s(
|
|
1466
|
+
({
|
|
1467
|
+
type: e = "error",
|
|
1468
|
+
ariaLive: a = "assertive",
|
|
1469
|
+
icon: t,
|
|
1470
|
+
className: i,
|
|
1471
|
+
children: n,
|
|
1472
|
+
...l
|
|
1473
|
+
}, o) => {
|
|
1474
|
+
const c = e === "error", u = e === "warning", h = t === void 0 ? Xt[e] : t;
|
|
1475
|
+
return /* @__PURE__ */ N(
|
|
1476
|
+
"div",
|
|
1477
|
+
{
|
|
1478
|
+
ref: o,
|
|
1479
|
+
role: Kt[a],
|
|
1480
|
+
"aria-live": a,
|
|
1481
|
+
className: d(
|
|
1482
|
+
"tilburg-validation-message",
|
|
1483
|
+
c && "utrecht-form-field-error-message",
|
|
1484
|
+
c && "tilburg-validation-message--error",
|
|
1485
|
+
u && "utrecht-form-field-description",
|
|
1486
|
+
u && "utrecht-form-field-description--warning",
|
|
1487
|
+
u && "tilburg-validation-message--warning",
|
|
1488
|
+
i
|
|
1489
|
+
),
|
|
1490
|
+
...l,
|
|
1491
|
+
children: [
|
|
1492
|
+
/* @__PURE__ */ r("span", { className: "tilburg-validation-message__icon", "aria-hidden": "true", children: h }),
|
|
1493
|
+
/* @__PURE__ */ r("span", { children: n })
|
|
1494
|
+
]
|
|
1495
|
+
}
|
|
1496
|
+
);
|
|
1497
|
+
}
|
|
1498
|
+
);
|
|
1499
|
+
Jt.displayName = "ValidationMessage";
|
|
1500
|
+
export {
|
|
1501
|
+
Le as Accordion,
|
|
1502
|
+
we as AccordionSection,
|
|
1503
|
+
$e as Alert,
|
|
1504
|
+
Ve as AlertDialog,
|
|
1505
|
+
We as Article,
|
|
1506
|
+
je as BadgeStatus,
|
|
1507
|
+
Ye as Breadcrumb,
|
|
1508
|
+
se as Button,
|
|
1509
|
+
ze as ButtonGroup,
|
|
1510
|
+
Xe as ButtonLink,
|
|
1511
|
+
Ke as Checkbox,
|
|
1512
|
+
Qe as Combobox,
|
|
1513
|
+
et as DataList,
|
|
1514
|
+
tt as DataListItem,
|
|
1515
|
+
at as DataListKey,
|
|
1516
|
+
rt as DataListValue,
|
|
1517
|
+
it as Document,
|
|
1518
|
+
nt as Fieldset,
|
|
1519
|
+
lt as FormField,
|
|
1520
|
+
ot as FormFieldDescription,
|
|
1521
|
+
ct as FormLabel,
|
|
1522
|
+
j as Heading1,
|
|
1523
|
+
Y as Heading2,
|
|
1524
|
+
z as Heading3,
|
|
1525
|
+
q as Heading4,
|
|
1526
|
+
X as Heading5,
|
|
1527
|
+
K as Heading6,
|
|
1528
|
+
st as HtmlContent,
|
|
1529
|
+
ut as LanguageToggle,
|
|
1530
|
+
ht as Link,
|
|
1531
|
+
mt as LoadingSpinner,
|
|
1532
|
+
de as Modal,
|
|
1533
|
+
bt as OrderedList,
|
|
1534
|
+
pt as Page,
|
|
1535
|
+
gt as PageContent,
|
|
1536
|
+
ft as PageFooter,
|
|
1537
|
+
_t as PageHeader,
|
|
1538
|
+
yt as Pagination,
|
|
1539
|
+
wt as Paragraph,
|
|
1540
|
+
Lt as PasswordInput,
|
|
1541
|
+
Ct as ProgressBar,
|
|
1542
|
+
Et as RadioButton,
|
|
1543
|
+
At as Select,
|
|
1544
|
+
Tt as Separator,
|
|
1545
|
+
St as SkipLink,
|
|
1546
|
+
It as Table,
|
|
1547
|
+
Mt as TableBody,
|
|
1548
|
+
Dt as TableCaption,
|
|
1549
|
+
Bt as TableCell,
|
|
1550
|
+
Ht as TableFooter,
|
|
1551
|
+
Pt as TableHeader,
|
|
1552
|
+
Rt as TableHeaderCell,
|
|
1553
|
+
Ft as TableRow,
|
|
1554
|
+
$t as Textarea,
|
|
1555
|
+
ue as Textbox,
|
|
1556
|
+
Ut as Tooltip,
|
|
1557
|
+
jt as UnorderedList,
|
|
1558
|
+
Yt as UnorderedListItem,
|
|
1559
|
+
Jt as ValidationMessage
|
|
1560
|
+
};
|