PageSourceSearch

https://mensenlinq.nl/build/assets/Home-DIEHbLxH.js

js mensenlinq.nl collected 2026-09-24 21:55:39 UTC 37,131 bytes, 953 lines download raw bytes

1import { a as require_react, d as __toESM, n as require_jsx_runtime, t as axios } from "./axios-D_Zw0bxE.js";
2import { Q as FontAwesomeIcon, a as init_moment, i as hooks, j as faMagnifyingGlass, nt as usePage, rt as router, s as Button, tt as useForm } from "./entry-app.js";
3import { t as Mensenlinq } from "./Mensenlinq-3-PTD-vo.js";
4import { t as relativeRoute } from "./relativeRoute-COMakHFU.js";
5import { c as CommercialType, o as Commercial_default, s as CommercialPageType, t as Page_default } from "./Page-CpPaJxrq.js";
6import { n as motion, t as Section_default } from "./Section-weZAlE6J.js";
7import { t as InputError } from "./InputError-D_63gI6d.js";
8import { t as useAjaxForm } from "./useAjaxForm-Bcrf8Vcs.js";
9import { t as Pagination } from "./Pagination-7FC60ab7.js";
10import { t as TextInput_default } from "./TextInput-CwWmrKtY.js";
11import "./TextInput-BchByz-i.js";
12import { t as Modal } from "./Modal-xpn2iaVt.js";
13import { t as Checkbox } from "./Checkbox-C81chCi3.js";
14import { n as Select, r as components } from "./Select-BkCWTeSg.js";
15import { t as debounce } from "./debounce-CxpxTJYT.js";
16import { t as PlaceOption_default } from "./PlaceOption-CtCnXfkh.js";
17import { t as require_prop_types } from "./prop-types-CH0As9d2.js";
18import { t as PersonCard } from "./PersonCard-BoJLqtnu.js";
19import { t as Tooltip_default } from "./Tooltip-Cl1c-wNx.js";
20import { n as SearchSize, t as Search } from "./Search-Ck6KGKWY.js";
21import { t as AdvertisementSection } from "./AdvertisementSection-BJPhwtsK.js";
22import { n as Tile, t as TileList } from "./TileList-B4BNhC1B.js";
23import { t as kaarsje_resormeren_default } from "./kaarsje-resormeren-dzwtjQnX.js";
24import { t as CallToAction_default } from "./CallToAction-BLxR3OT2.js";
25import { t as useWindowSize } from "./useWindowSize-bqKM0Sc1.js";
26import { n as email_default, r as Icon_default, t as searchPrompt_default } from "./searchPrompt-BTlMoWp2.js";
27//#region resources/js/Organisms/Hero/Hero.module.scss
28var import_react = /* @__PURE__ */ __toESM(require_react(), 1);
29var Hero_module_default = {
30	hero: "_hero_168g6_1",
31	videoBackground: "_videoBackground_168g6_6",
32	content: "_content_168g6_9",
33	video: "_video_168g6_6",
34	videoOverlay: "_videoOverlay_168g6_26"
35};
36//#endregion
37//#region resources/js/Organisms/Hero/Hero.tsx
38var import_jsx_runtime = require_jsx_runtime();
39function Hero() {
40	return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("section", {
41		className: `bg-beige ${Hero_module_default.hero}`,
42		children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
43			className: Hero_module_default.videoBackground,
44			children: [
45				/* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
46					className: Hero_module_default.content,
47					children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("h1", {
48						className: "section__title",
49						children: "De plek waar een overlijden gedeeld wordt"
50					})
51				}),
52				/* @__PURE__ */ (0, import_jsx_runtime.jsx)("video", {
53					className: Hero_module_default.video,
54					playsInline: true,
55					muted: true,
56					autoPlay: true,
57					loop: true,
58					children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("source", {
59						src: "/header-movie.mp4",
60						type: "video/mp4"
61					})
62				}),
63				/* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className: Hero_module_default.videoOverlay })
64			]
65		})
66	});
67}
68//#endregion
69//#region resources/js/Organisms/CallToAction/Onboarding.tsx
70function Onboarding() {
71	const useNewBestelstraat = usePage().props.bestelstraat ?? false;
72	return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(CallToAction_default, {
73		imageBackground: kaarsje_resormeren_default,
74		title: "Overlijden bekendmaken",
75		content: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", { children: "Maak een overlijden bekend via een online rouwpagina of via een rouwadvertentie in de krant." }), useNewBestelstraat ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)("a", {
76			className: "button",
77			href: relativeRoute("order"),
78			children: "Online rouwbericht opstellen"
79		}) : /* @__PURE__ */ (0, import_jsx_runtime.jsx)("a", {
80			className: "button",
81			href: "https://www.familieberichten.nl/home",
82			target: "_blank",
83			children: "Rouwadvertentie opstellen"
84		})] })
85	});
86}
87//#endregion
88//#region resources/js/Organisms/Blog/Latest.tsx
89function BlogsLatest({ articles }) {
90	return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TileList, { children: articles.map((article, index) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Tile, {
91		article,
92		baseUrl: "/in-memoriam"
93	}, index)) });
94}
95//#endregion
96//#region resources/images/examples/newsletter.png
97var newsletter_default = "/build/assets/newsletter-DG9goDHQ.png";
98var Subscribe_module_default = {
99	container: "_container_1d4xo_1",
100	subContainer: "_subContainer_1d4xo_5",
101	formContainer: "_formContainer_1d4xo_9",
102	field: "_field_1d4xo_50"
103};
104//#endregion
105//#region resources/js/Organisms/Newsletter/Subscribe.tsx
106function NewsletterSubscribe() {
107	const { data, setData, post, processing, success, setSuccess, errors, setError, clearErrors, reset } = useAjaxForm({});
108	const handleSubmit = async (e) => {
109		e.preventDefault();
110		await post(relativeRoute("newsletter-subscribe"), {});
111	};
112	return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("section", {
113		className: Subscribe_module_default.container,
114		children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
115			className: `container ${Subscribe_module_default.subContainer}`,
116			children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
117				className: Subscribe_module_default.formContainer,
118				children: [
119					/* @__PURE__ */ (0, import_jsx_runtime.jsx)("h2", { children: "De nieuwste verhalen in jouw mailbox" }),
120					success ? /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", { children: "Je hebt je ingeschreven in de nieuwsbrief." }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("button", {
121						onClick: () => setSuccess(false),
122						children: "Opnieuw"
123					})] }) : /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", { children: "Wekelijks de nieuwste verhalen van Mensenlinq.nl ontvangen in jouw mailbox? Schrijf je in!" }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("form", {
124						onSubmit: handleSubmit,
125						children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("fieldset", {
126							disabled: processing,
127							children: [
128								/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
129									className: Subscribe_module_default.field,
130									children: [
131										/* @__PURE__ */ (0, import_jsx_runtime.jsx)("label", {
132											htmlFor: "newsletter__name",
133											children: "Naam"
134										}),
135										/* @__PURE__ */ (0, import_jsx_runtime.jsx)("input", {
136											type: "text",
137											value: data?.name ?? "",
138											onChange: (e) => setData("name", e.target.value),
139											id: "newsletter__name",
140											placeholder: "Jouw naam"
141										}),
142										/* @__PURE__ */ (0, import_jsx_runtime.jsx)(InputError, { message: errors.name })
143									]
144								}),
145								/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
146									className: Subscribe_module_default.field,
147									children: [
148										/* @__PURE__ */ (0, import_jsx_runtime.jsx)("label", {
149											htmlFor: "newsletter__email",
150											children: "E-mailadres"
151										}),
152										/* @__PURE__ */ (0, import_jsx_runtime.jsx)("input", {
153											type: "text",
154											value: data?.email ?? "",
155											onChange: (e) => setData("email", e.target.value),
156											id: "newsletter__email",
157											placeholder: "Jouw e-mailadres"
158										}),
159										/* @__PURE__ */ (0, import_jsx_runtime.jsx)(InputError, { message: errors.email })
160									]
161								}),
162								/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("button", { children: "Inschrijven" }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(InputError, { message: errors.recaptcha })] })
163							]
164						})
165					})] }),
166					/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("p", { children: [
167						"Je kunt je op elk moment uitschrijven. Voor meer informatie, lees ons ",
168						/* @__PURE__ */ (0, import_jsx_runtime.jsx)("a", {
169							href: relativeRoute("privacy-statement"),
170							target: "_blank",
171							children: "privacy statement"
172						}),
173						"."
174					] })
175				]
176			})
177		}), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("img", {
178			src: newsletter_default,
179			alt: ""
180		})]
181	});
182}
183var ObituarySearch_module_default = {
184	simpleSearchSection: "_simpleSearchSection_1lxme_1",
185	searchContainer: "_searchContainer_1lxme_4",
186	searchForm: "_searchForm_1lxme_8",
187	search: "_search_1lxme_4",
188	extendedSearch: "_extendedSearch_1lxme_21",
189	closed: "_closed_1lxme_25"
190};
191var PersonSearch_module_default = {
192	grid: "_grid_xl8fl_1",
193	simple: "_simple_xl8fl_8",
194	birthDate: "_birthDate_xl8fl_11",
195	dateOfPlacing: "_dateOfPlacing_xl8fl_11",
196	deceasedFrom: "_deceasedFrom_xl8fl_11",
197	deceasedTo: "_deceasedTo_xl8fl_11",
198	firstName: "_firstName_xl8fl_14",
199	lastName: "_lastName_xl8fl_17",
200	papers: "_papers_xl8fl_20",
201	place: "_place_xl8fl_23",
202	province: "_province_xl8fl_26",
203	options: "_options_xl8fl_41",
204	actions: "_actions_xl8fl_44",
205	search: "_search_xl8fl_56"
206};
207var Date_module_default = {
208	date: "_date_1ee43_1",
209	day: "_day_1ee43_18",
210	month: "_month_1ee43_21",
211	year: "_year_1ee43_24"
212};
213//#endregion
214//#region resources/js/Atoms/Date/Date.tsx
215init_moment();
216var import_prop_types = /* @__PURE__ */ __toESM(require_prop_types(), 1);
217var stringToStructure = (input) => {
218	if (!input) return {};
219	const [year, month, day] = input.split("-");
220	return {
221		year: Number(year),
222		month: Number(month),
223		day: Number(day)
224	};
225};
226var structureToString = (input) => {
227	const now = hooks();
228	let result = "";
229	if (input.year) result = input.year.toString();
230	if (input.month) {
231		if (!input.year) result += now.year().toString();
232		result += "-" + input.month.toString().padStart(2, "0");
233	}
234	if (input.day) {
235		if (!input.year) result += now.year().toString();
236		if (!input.month) result += "-" + (now.month() + 1).toString().padStart(2, "0");
237		result += "-" + input.day.toString().padStart(2, "0");
238	}
239	return result;
240};
241var Date = ({ value: initValue, type = "date", onChange }) => {
242	const days = Array(31).fill(0);
243	const months = hooks().localeData().months();
244	const currentYear = hooks().year();
245	const value = stringToStructure(initValue);
246	const renderYears = () => {
247		const result = [];
248		const isBirthDate = type === "birthdate";
249		const fromYear = isBirthDate ? 1900 : 1970;
250		for (let year = currentYear; year >= fromYear; year--) result.push(/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("option", {
251			value: year,
252			children: [
253				year,
254				" ",
255				year < 2006 && !isBirthDate ? "*" : ""
256			]
257		}, year));
258		return result;
259	};
260	const handleDayChange = (e) => {
261		let newDate = { ...value };
262		if (e.target.value) newDate.day = parseInt(e.target.value);
263		else delete newDate.day;
264		onChange(structureToString(newDate));
265	};
266	const handleMonthChange = (e) => {
267		let newDate = { ...value };
268		if (e.target.value) newDate.month = parseInt(e.target.value);
269		else {
270			delete newDate.month;
271			delete newDate.day;
272		}
273		onChange(structureToString(newDate));
274	};
275	const handleYearChange = (e) => {
276		let newDate = { ...value };
277		if (e.target.value) newDate.year = parseInt(e.target.value);
278		else {
279			delete newDate.year;
280			delete newDate.month;
281			delete newDate.day;
282		}
283		onChange(structureToString(newDate));
284	};
285	return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
286		className: Date_module_default.date,
287		children: [
288			/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("select", {
289				className: Date_module_default.day,
290				value: value?.day || "",
291				onChange: handleDayChange,
292				children: [
293					/* @__PURE__ */ (0, import_jsx_runtime.jsx)("option", {
294						value: "",
295						disabled: true,
296						hidden: true,
297						children: "Dag"
298					}),
299					/* @__PURE__ */ (0, import_jsx_runtime.jsx)("option", {
300						value: "",
301						children: "Hele maand"
302					}),
303					days.map((day, index) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("option", {
304						value: index + 1,
305						children: index + 1
306					}, index))
307				]
308			}),
309			/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("select", {
310				className: Date_module_default.month,
311				value: value?.month || "",
312				onChange: handleMonthChange,
313				children: [
314					/* @__PURE__ */ (0, import_jsx_runtime.jsx)("option", {
315						value: "",
316						disabled: true,
317						hidden: true,
318						children: "Maand"
319					}),
320					/* @__PURE__ */ (0, import_jsx_runtime.jsx)("option", {
321						value: "",
322						children: "Hele jaar"
323					}),
324					months.map((month, index) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("option", {
325						value: index + 1,
326						children: month
327					}, index))
328				]
329			}),
330			/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("select", {
331				className: Date_module_default.year,
332				value: value?.year || "",
333				onChange: handleYearChange,
334				children: [
335					/* @__PURE__ */ (0, import_jsx_runtime.jsx)("option", {
336						value: "",
337						disabled: true,
338						hidden: true,
339						children: "Jaar"
340					}),
341					/* @__PURE__ */ (0, import_jsx_runtime.jsx)("option", { value: "" }),
342					renderYears()
343				]
344			})
345		]
346	});
347};
348Date.propTypes = {
349	type: import_prop_types.default.oneOf(["date", "birthdate"]),
350	onChange: import_prop_types.default.func
351};
352//#endregion
353//#region resources/js/Atoms/Select/MultiPlaceOrRegionSelect.tsx
354var MultiPlaceOrRegionSelect_default = (props) => {
355	const debouncedPlaces = debounce((inputValue) => {
356		return new Promise(async (resolve) => {
357			resolve((await axios.get(relativeRoute("region-search") + "?search=" + inputValue)).data);
358		});
359	}, 500, { leading: true });
360	const loadOptions = (inputValue) => {
361		return debouncedPlaces(inputValue);
362	};
363	const MultiValueComponent = (props) => {
364		const option = props.data;
365		let title = option.label;
366		switch (option.type) {
367			case "municipality":
368				title = `Gem. ${title}`;
369				break;
370			case "province": title = `Prov. ${title}`;
371		}
372		return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(components.MultiValue, {
373			...props,
374			children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
375				title: option.description,
376				children: title
377			})
378		});
379	};
380	return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Select, {
381		...props,
382		name: "place",
383		isAsync: true,
384		isMulti: true,
385		isClearable: true,
386		placeholder: "Zoek naar één of meer plaatsen of gebieden",
387		noOptionsMessage: () => "Geen zoekresultaten",
388		loadingMessage: () => "Bezig met zoeken...",
389		loadOptions,
390		components: {
391			DropdownIndicator: () => null,
392			IndicatorSeparator: () => null,
393			Option: PlaceOption_default,
394			MultiValue: MultiValueComponent
395		}
396	});
397};
398//#endregion
399//#region resources/js/Organisms/PersonList/PersonSearch.tsx
400var PersonSearch_default = ({ data, errors, setData, reset, onSubmit, papers, provinces, simple, className }) => {
401	const [extended, setExtended] = (0, import_react.useState)(!simple);
402	function handleSetPapers(papers) {
403		setData("papers", papers.map((paper) => paper.value));
404	}
405	const handleSetPlaces = (places) => {
406		setData("places", places);
407	};
408	const handleSubmit = (e) => {
409		e.preventDefault();
410		onSubmit(e);
411	};
412	return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
413		className: [className, PersonSearch_module_default.search].filter(Boolean).join(" "),
414		children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("form", {
415			className: `${PersonSearch_module_default.grid} ${!extended && PersonSearch_module_default.simple}`,
416			onSubmit: (e) => handleSubmit(e),
417			autoComplete: "off",
418			"data-testid": "person-search-form",
419			children: [
420				/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
421					className: PersonSearch_module_default.firstName,
422					children: [
423						/* @__PURE__ */ (0, import_jsx_runtime.jsx)("label", { children: "Voornaam" }),
424						/* @__PURE__ */ (0, import_jsx_runtime.jsx)(TextInput_default, {
425							value: data.firstName ?? "",
426							name: "first_name",
427							onChange: (e) => setData("firstName", e.target.value),
428							fullWidth: true,
429							autoComplete: "off"
430						}),
431						/* @__PURE__ */ (0, import_jsx_runtime.jsx)(InputError, { message: errors.firstName })
432					]
433				}),
434				/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
435					className: PersonSearch_module_default.lastName,
436					children: [
437						/* @__PURE__ */ (0, import_jsx_runtime.jsx)("label", { children: "Achternaam" }),
438						/* @__PURE__ */ (0, import_jsx_runtime.jsx)(TextInput_default, {
439							value: data.lastName ?? "",
440							name: "last_name",
441							onChange: (e) => setData("lastName", e.target.value),
442							fullWidth: true,
443							autoComplete: "off"
444						}),
445						/* @__PURE__ */ (0, import_jsx_runtime.jsx)(InputError, { message: errors.lastName })
446					]
447				}),
448				/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
449					className: PersonSearch_module_default.papers,
450					children: [
451						/* @__PURE__ */ (0, import_jsx_runtime.jsx)("label", { children: "Geplaatst in" }),
452						/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Select, {
453							placeholder: "Zoek naar krant of dagblad",
454							name: "papers",
455							isClearable: true,
456							isMulti: true,
457							options: papers,
458							value: papers.filter((paper) => data.papers?.includes(paper.value)),
459							onChange: (papers) => handleSetPapers(papers),
460							noOptionsMessage: () => "Geen zoekresultaten",
461							dataTestid: "papers-select"
462						}),
463						/* @__PURE__ */ (0, import_jsx_runtime.jsx)(InputError, { message: errors.papers })
464					]
465				}),
466				/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
467					className: PersonSearch_module_default.place,
468					children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("label", { children: "Plaats of Gemeente" }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(MultiPlaceOrRegionSelect_default, {
469						dataTestid: "places",
470						value: data.places ?? null,
471						onChange: (places) => handleSetPlaces(places)
472					})]
473				}),
474				/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
475					className: PersonSearch_module_default.province,
476					children: [
477						/* @__PURE__ */ (0, import_jsx_runtime.jsx)("label", { children: "Provincie" }),
478						/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Select, {
479							name: "provinces",
480							dataTestid: "province-select",
481							isClearable: true,
482							options: provinces,
483							getOptionValue: (option) => option.slug,
484							getOptionLabel: (option) => option.title,
485							value: data.province,
486							onChange: (province) => setData("province", province)
487						}),
488						/* @__PURE__ */ (0, import_jsx_runtime.jsx)(InputError, { message: errors.province })
489					]
490				}),
491				/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
492					className: PersonSearch_module_default.birthDate,
493					children: [
494						/* @__PURE__ */ (0, import_jsx_runtime.jsx)("label", { children: "Geboortedatum" }),
495						/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Date, {
496							type: "birthdate",
497							value: data.birthDate ?? "",
498							onChange: (value) => setData("birthDate", value)
499						}),
500						/* @__PURE__ */ (0, import_jsx_runtime.jsx)(InputError, { message: errors.birthDate })
501					]
502				}),
503				/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
504					className: PersonSearch_module_default.dateOfPlacing,
505					children: [
506						/* @__PURE__ */ (0, import_jsx_runtime.jsx)("label", { children: "Specifieke plaatsingsdatum" }),
507						/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Date, {
508							value: data.dateOfPlacing ?? "",
509							onChange: (value) => setData("dateOfPlacing", value)
510						}),
511						/* @__PURE__ */ (0, import_jsx_runtime.jsx)(InputError, { message: errors.dateOfPlacing })
512					]
513				}),
514				/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
515					className: PersonSearch_module_default.deceasedFrom,
516					children: [
517						/* @__PURE__ */ (0, import_jsx_runtime.jsx)("label", { children: "Overlijdensdatum vanaf" }),
518						/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Date, {
519							value: data.deceasedFrom ?? "",
520							onChange: (value) => setData("deceasedFrom", value)
521						}),
522						/* @__PURE__ */ (0, import_jsx_runtime.jsx)(InputError, { message: errors.deceasedFrom })
523					]
524				}),
525				/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
526					className: PersonSearch_module_default.deceasedTo,
527					children: [
528						/* @__PURE__ */ (0, import_jsx_runtime.jsx)("label", { children: "Overlijdensdatum t/m" }),
529						/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Date, {
530							value: data.deceasedTo ?? "",
531							onChange: (value) => setData("deceasedTo", value)
532						}),
533						/* @__PURE__ */ (0, import_jsx_runtime.jsx)(InputError, { message: errors.deceasedTo })
534					]
535				}),
536				/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
537					className: PersonSearch_module_default.options,
538					children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Checkbox, {
539						className: "rounded-sm !border border-gray-900 text-indigo-600 shadow-xs focus:ring-indigo-500",
540						name: "fuzzy_search",
541						id: "fuzzy-search",
542						checked: data.fuzzySearch,
543						onChange: (e) => setData("fuzzySearch", e.target.checked)
544					}), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("label", {
545						htmlFor: "fuzzy-search",
546						children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
547							className: "ms-2 text-sm text-gray-600",
548							children: "Ruimer zoeken"
549						})
550					})]
551				}),
552				/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
553					className: PersonSearch_module_default.actions,
554					children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Button, {
555						outlined: true,
556						onClick: () => reset(),
557						"data-testid": "reset",
558						children: "Alles wissen"
559					}), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Button, {
560						type: "submit",
561						primary: true,
562						children: "Zoeken"
563					})]
564				})
565			]
566		})
567	});
568};
569var PersonList_module_default = {
570	obituaries: "_obituaries_1jmih_1",
571	adBetween: "_adBetween_1jmih_26",
572	adSticky: "_adSticky_1jmih_29"
573};
574var StickyContainer_module_default = {
575	container: "_container_elw5l_1",
576	content: "_content_elw5l_5",
577	sticky: "_sticky_elw5l_8",
578	hideStickyOnMobile: "_hideStickyOnMobile_elw5l_14"
579};
580//#endregion
581//#region resources/js/Molecules/StickyContainer/StickyContainer.tsx
582function StickyContainer({ component, children, className, hideStickOnMobile }) {
583	return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
584		className: `${StickyContainer_module_default.container} ${className || ""}`,
585		children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
586			className: StickyContainer_module_default.content,
587			children
588		}), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
589			className: `${StickyContainer_module_default.sticky} ${hideStickOnMobile ? StickyContainer_module_default.hideStickyOnMobile : ""}`,
590			children: component
591		})]
592	});
593}
594//#endregion
595//#region resources/js/Organisms/PersonList/PersonList.tsx
596var PersonList_default = ({ obituaries }) => {
597	const { isTablet, isMobile } = useWindowSize();
598	return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(StickyContainer, {
599		component: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Commercial_default, {
600			type: isTablet ? CommercialType.Leaderboard : CommercialType.HalfPageSkyscraper,
601			top: true
602		}),
603		children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
604			className: PersonList_module_default.obituaries,
605			children: obituaries.map((obituary, index) => {
606				return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_react.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(PersonCard, { person: obituary.person }) }, index);
607			})
608		})
609	});
610};
611//#endregion
612//#region resources/js/Organisms/Modals/SaveSearchModal.tsx
613/**
614* @param onSubmit
615* @param onCancel
616* @param isOpen
617* @param isLoading
618* @param defaultValues
619* @param query
620* @param inputErrors
621*/
622var SaveSearchModal_default = ({ onSubmit, onCancel, isOpen, isLoading, defaultValues, query }) => {
623	const [errors, setErrors] = (0, import_react.useState)([]);
624	const [isSend, setIsSend] = (0, import_react.useState)(false);
625	const { data, setData, reset } = useForm({
626		name: "",
627		email: "",
628		query,
629		interval: "weekly",
630		newsletter: false
631	});
632	const prompt = searchPrompt_default(query);
633	const handleSubmit = async (e) => {
634		e.preventDefault();
635		try {
636			await axios.post(relativeRoute("search.save"), data);
637			setIsSend(true);
638		} catch (e) {
639			const data = e.response.data;
640			setErrors(data.errors);
641		}
642		if (onSubmit) onSubmit(data);
643	};
644	(0, import_react.useEffect)(() => {
645		if (isOpen && query) setData({
646			...data,
647			query
648		});
649		if (!isOpen) {
650			setIsSend(false);
651			reset();
652		}
653	}, [isOpen]);
654	if (!isOpen) return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_jsx_runtime.Fragment, {});
655	return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Modal, {
656		title: "Bewaar zoekopdracht",
657		onCancel,
658		children: [!prompt && /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_jsx_runtime.Fragment, { children: "Je hebt geen zoekopdracht gegeven. Sluit dit venster, vul enkele zoek parameters in en open opnieuw 'Bewaar zoekopdracht'." }), prompt && /* @__PURE__ */ (0, import_jsx_runtime.jsx)("form", {
659			onSubmit: handleSubmit,
660			"data-testid": "save-search-form",
661			children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("fieldset", {
662				disabled: isLoading,
663				children: [
664					/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { children: [
665						/* @__PURE__ */ (0, import_jsx_runtime.jsx)("label", { children: "Je zoekopdracht: " }),
666						prompt,
667						/* @__PURE__ */ (0, import_jsx_runtime.jsx)("hr", {})
668					] }),
669					isSend && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { children: [
670						"Je zoekopdracht is opgeslagen. Je hebt een email ontvangen om de opdracht te bevestigen.",
671						/* @__PURE__ */ (0, import_jsx_runtime.jsx)("br", {}),
672						"Met deze link kun je ook je andere opdrachten beheren."
673					] }),
674					!isSend && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, { children: [
675						/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("label", { children: ["Je naam:", /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TextInput_default, {
676							value: data.name,
677							onChange: (e) => setData("name", e.target.value),
678							fullWidth: true
679						})] }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(InputError, { message: errors.name })] }),
680						/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("label", { children: ["Je e-mailadres: \xA0", /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TextInput_default, {
681							value: data.email,
682							onChange: (e) => setData("email", e.target.value),
683							fullWidth: true
684						})] }
684), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(InputError, { message: errors.email })] }),
685						/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
686							className: "hidden",
687							children: [/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("label", { children: [
688								"Hoe vaak wil je een email ontvangen? \xA0",
689								/* @__PURE__ */ (0, import_jsx_runtime.jsx)("br", {}),
690								/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("label", { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("input", {
691									type: "radio",
692									name: "interval",
693									value: "daily",
694									checked: data.interval === "daily",
695									onChange: (e) => setData("interval", e.target.value)
696								}), " Dagelijks"] }),
697								/* @__PURE__ */ (0, import_jsx_runtime.jsx)("br", {}),
698								/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("label", { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("input", {
699									type: "radio",
700									name: "interval",
701									value: "weekly",
702									checked: data.interval === "weekly",
703									onChange: (e) => setData("interval", e.target.value)
704								}), " Wekelijks"] }),
705								/* @__PURE__ */ (0, import_jsx_runtime.jsx)("br", {})
706							] }
706), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(InputError, { message: errors.email })]
707						}),
708						/* @__PURE__ */ (0, import_jsx_runtime.jsx)("footer", { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Button, {
709							isLoading,
710							children: "Opslaan"
711						}) })
712					] })
713				]
714			})
715		})]
716	});
717};
718//#endregion
719//#region resources/js/Organisms/ObituarySearch/ObituarySearch.tsx
720var ObituarySearch_default = ({ obituaries, errors: initialErrors, search, papers, provinces }) => {
721	const [showSaveSearchModal, setShowSaveSearchModal] = (0, import_react.useState)(false);
722	const useNewBestelstraat = usePage().props.bestelstraat ?? false;
723	const { data, setData, get, processing, errors, setError, clearErrors, reset, transform } = useForm({
724		birthDate: search.birthDate ?? "",
725		dateOfPlacing: search.dateOfPlacing ?? "",
726		deceasedFrom: search.deceasedFrom ?? "",
727		deceasedTo: search.deceasedTo ?? "",
728		page: 1,
729		fuzzySearch: search.fuzzySearch ?? false,
730		papers: search.papers ?? [],
731		places: search.places ?? [],
732		province: search.province ?? "",
733		firstName: search.firstName ?? "",
734		lastName: search.lastName ?? ""
735	});
736	(0, import_react.useEffect)(() => {
737		setError(initialErrors);
738	}, []);
739	const performSearchObituaries = (data = {}) => {
740		router.get("/", data, {
741			preserveState: true,
742			preserveScroll: true,
743			replace: true,
744			only: ["obituaries"],
745			onSuccess: () => {
746				requestAnimationFrame(() => {
747					const el = document.getElementById("obituaries");
748					if (el) {
749						const distance = el.getBoundingClientRect().top + window.scrollY;
750						window.scrollTo({
751							top: distance - 120,
752							behavior: "smooth"
753						});
754					}
755				});
756			}
757		});
758	};
759	const handleSimpleSearch = (e) => {
760		e.preventDefault();
761		performSearchObituaries({
762			...data,
763			type: "simple"
764		});
765	};
766	const handleExtendedSearch = (e) => {
767		e.preventDefault();
768		performSearchObituaries({
769			...data,
770			type: "extended"
771		});
772	};
773	const handleReset = () => {
774		reset();
775		performSearchObituaries();
776	};
777	const handlePaginate = (page) => {
778		performSearchObituaries({
779			...data,
780			page
781		});
782	};
783	const [openSearch, setOpenSearch] = (0, import_react.useState)(localStorage.getItem("obituarySearchState") === "open");
784	(0, import_react.useEffect)(() => localStorage.setItem("obituarySearchState", openSearch ? "open" : "closed"), [openSearch]);
785	const toggleSearch = () => {
786		setOpenSearch((state) => !state);
787	};
788	const query = {
789		first_name: data.firstName ?? "",
790		last_name: data.lastName ?? "",
791		birth_date: data.birthDate ?? "",
792		placement_date: data.dateOfPlacing ?? "",
793		deceased_date_from: data.deceasedFrom ?? "",
794		deceased_date_to: data.deceasedTo ?? "",
795		places: data.places ?? [],
796		province: data.province,
797		papers: data.papers?.map((paper) => ({
798			id: paper,
799			title: paper
800		})) ?? []
801	};
802	const handleSaveSearchModel = () => {};
803	return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, { children: [
804		/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Section_default, {
805			light: true,
806			center: true,
807			className: ObituarySearch_module_default.simpleSearchSection,
808			children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
809				className: ObituarySearch_module_default.searchContainer,
810				children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(motion.div, {
811					initial: true,
812					animate: { opacity: openSearch ? 0 : 1 },
813					transition: {
814						duration: .3,
815						ease: "easeInOut"
816					},
817					children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("form", {
818						className: ObituarySearch_module_default.searchForm,
819						onSubmit: handleSimpleSearch,
820						"data-testid": "hero-search-form",
821						children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Search, {
822							placeholder: "Zoeken op voor- of achternaam",
823							size: SearchSize.Large,
824							value: data.name,
825							onChange: (input) => setData("name", input),
826							autoComplete: "off"
827						})
828					})
829				}), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
830					className: ObituarySearch_module_default.search,
831					children: [useNewBestelstraat && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("a", {
832						className: "btn",
833						href: relativeRoute("order"),
834						children: ["Ik wil een overlijden delen\xA0", /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Mensenlinq, {
835							color: "red",
836							width: 20,
837							height: 20
838						})]
839					}), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Button, {
840						variant: "outlined",
841						className: "btn",
842						onClick: toggleSearch,
843						children: [
844							"Ik wil ",
845							openSearch ? "eenvoudig" : "uitgebreid",
846							" zoeken\xA0",
847							/* @__PURE__ */ (0, import_jsx_runtime.jsx)(FontAwesomeIcon, { icon: faMagnifyingGlass })
848						]
849					})]
850				})]
851			})
852		}),
853		/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Section_default, {
854			light: true,
855			className: [ObituarySearch_module_default.extendedSearch, ...openSearch ? [] : [ObituarySearch_module_default.closed]].join(" "),
856			wide: true,
857			children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(motion.div, {
858				initial: false,
859				animate: {
860					height: openSearch ? "auto" : 0,
861					opacity: openSearch ? 1 : 0
862				},
863				transition: {
864					duration: .3,
865					ease: "easeInOut"
866				},
867				children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(PersonSearch_default, {
868					data,
869					errors,
870					setData,
871					reset: () => handleReset(),
872					onSubmit: handleExtendedSearch,
873					papers,
874					provinces
875				}), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
876					className: "flex justify-end gap-2 mt-2",
877					children: [/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
878						className: "cursor-pointer hover:text-red-700",
879						onClick: () => setShowSaveSearchModal(true),
880						children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Icon_default, { src: email_default }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { children: "Bewaar zoekopdracht" })]
881					}), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Tooltip_default, { children: "Bewaar de zoekopdracht en ontvang wekelijks de overlijdensberichten die hieraan voldoen in de mailbox. Je kunt meerdere zoekopdrachten opslaan, en je kunt de zoekopdracht(en) altijd aanpassen of verwijderen." })]
882				})]
883			})
884		}),
885		/* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Section_default, {
886			light: true,
887			center: true,
888			className: ObituarySearch_module_default.section,
889			wide: true,
890			title: "Overlijdensberichten",
891			subtitle: "De meest actuele overlijdensberichten",
892			children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(PersonList_default, { obituaries: obituaries.items }
892), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Pagination, {
893				page: obituaries.page,
894				pages: obituaries.pages,
895				onChange: (page) => {
896					handlePaginate(page);
897				}
898			})]
899		}),
900		/* @__PURE__ */ (0, import_jsx_runtime.jsx)(SaveSearchModal_default, {
901			isOpen: showSaveSearchModal,
902			onSubmit: handleSaveSearchModel,
903			onCancel: () => setShowSaveSearchModal(false),
904			query
905		})
906	] });
907};
908//#endregion
909//#region resources/js/Templates/Home/Home.tsx
910var Home_default$1 = ({ obituaries, papers, provinces, articles, errors }) => {
911	return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, { children: [
912		/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Hero, {}),
913		/* @__PURE__ */ (0, import_jsx_runtime.jsx)(ObituarySearch_default, {
914			obituaries: obituaries.items,
915			papers,
916			provinces,
917			errors,
918			search: obituaries.search
919		}),
920		/* @__PURE__ */ (0, import_jsx_runtime.jsx)(AdvertisementSection, { className: "bg-beige p-5" }),
921		/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Onboarding, {}),
922		/* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Section_default, {
923			lighter: true,
924			center: true,
925			title: "De laatste verhalen",
926			subtitle: "Voor eeuwig en altijd hun verhaal",
927			children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(BlogsLatest, { articles }
927), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
928				className: "actions",
929				children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("a", {
930					className: "btn",
931					href: "/verhalen",
932					children: "Toon meer"
933				})
934			})]
935		}),
936		/* @__PURE__ */ (0, import_jsx_runtime.jsx)(AdvertisementSection, {}),
937		/* @__PURE__ */ (0, import_jsx_runtime.jsx)(NewsletterSubscribe, {})
938	] });
939};
940//#endregion
941//#region resources/js/Pages/Home.tsx
942var Home_default = (props) => {
943	return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Page_default, {
944		fullTitle: "Mensenlinq - De plek waar een overlijden gedeeld wordt",
945		pageType: CommercialPageType.Home,
946		adUnit: "homepage",
947		children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Home_default$1, { ...props })
948	});
949};
950//#endregion
951export { Home_default as default };
952
953//# sourceMappingURL=Home-DIEHbLxH.js.map

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.