mirror of
https://github.com/amir20/dozzle.git
synced 2025-12-26 07:13:41 +01:00
17 lines
443 B
TypeScript
17 lines
443 B
TypeScript
import { JSONObject, LogEntry } from "@/models/LogEntry";
|
|
|
|
const lastSelectedItem = ref<LogEntry<string | JSONObject> | undefined>(undefined);
|
|
export const useLogSearchContext = () => {
|
|
const { resetSearch } = useSearchFilter();
|
|
|
|
function handleJumpLineSelected(e: Event, item: LogEntry<string | JSONObject>) {
|
|
lastSelectedItem.value = item;
|
|
resetSearch();
|
|
}
|
|
|
|
return {
|
|
lastSelectedItem,
|
|
handleJumpLineSelected,
|
|
};
|
|
};
|