Bugfix
This commit is contained in:
@@ -158,11 +158,12 @@ Contao 5 – Frontend Module Template
|
|||||||
for (const hit of hits) {
|
for (const hit of hits) {
|
||||||
|
|
||||||
const node = template.content.cloneNode(true);
|
const node = template.content.cloneNode(true);
|
||||||
const item = node.querySelector(':scope > .search-item');
|
const item = node.children[0]; // 🔒 sicher
|
||||||
|
|
||||||
// 🔥 HIER DEBUG (einmal testen!)
|
// DEBUG – einmal prüfen
|
||||||
console.log('TYPE FROM MEILI:', hit.type);
|
console.log('TYPE:', hit.type);
|
||||||
|
|
||||||
|
// Type → CSS-Klasse
|
||||||
if (hit.type) {
|
if (hit.type) {
|
||||||
item.classList.add(
|
item.classList.add(
|
||||||
String(hit.type)
|
String(hit.type)
|
||||||
|
|||||||
Reference in New Issue
Block a user