Run prettier on all relevant files

This commit is contained in:
Claudio Ortolina
2026-05-05 10:45:25 +01:00
parent 0b1f839091
commit 5888324cc7
17 changed files with 447 additions and 404 deletions
+11 -4
View File
@@ -1,4 +1,8 @@
export default function createNavigationHook({ getContainer, inputId, onSelect }) {
export default function createNavigationHook({
getContainer,
inputId,
onSelect,
}) {
return {
mounted() {
this.selectedIndex = -1;
@@ -89,13 +93,16 @@ export default function createNavigationHook({ getContainer, inputId, onSelect }
if (searchInput) {
searchInput.focus();
}
} else if (this.selectedIndex >= 0 && this.selectedIndex < results.length) {
} else if (
this.selectedIndex >= 0 &&
this.selectedIndex < results.length
) {
const selectedResult = results[this.selectedIndex];
selectedResult.setAttribute("aria-selected", "true");
selectedResult.scrollIntoView({
block: "nearest",
behavior: "smooth"
behavior: "smooth",
});
}
},
@@ -105,6 +112,6 @@ export default function createNavigationHook({ getContainer, inputId, onSelect }
if (!container) return [];
return Array.from(container.querySelectorAll('[role="option"]'));
}
},
};
}
+2 -2
View File
@@ -4,5 +4,5 @@ export default {
},
updated() {
this.el.innerText = parseInt(this.el.innerText).toLocaleString();
}
}
},
};
+1 -1
View File
@@ -9,5 +9,5 @@ export default createNavigationHook({
} else {
hook.navigateUp();
}
}
},
});
+1 -1
View File
@@ -9,5 +9,5 @@ export default createNavigationHook({
} else {
hook.navigateUp();
}
}
},
});
+1 -1
View File
@@ -28,7 +28,7 @@ export default {
onEnd: () => {
const items = this.el.querySelectorAll("[data-sortable-item]");
const recordIds = Array.from(items).map(
(item) => item.dataset.recordId
(item) => item.dataset.recordId,
);
const payload = { record_ids: recordIds };
@@ -2,5 +2,5 @@ import createNavigationHook from "./create-navigation-hook";
export default createNavigationHook({
getContainer: () => document.getElementById("universal-search-root"),
inputId: "universal-search-input"
inputId: "universal-search-input",
});