import { useBookingTicket } from "./bookingTicket.js";
import { useMemoizedFn } from "ahooks";
//#region src/components/ticketBooking/hooks/pisellos/useScanManager.ts
const useScanManager = () => {
	const bookingTicket = useBookingTicket();
	return {
		disableAllScanListeners: useMemoizedFn(() => {
			if (!bookingTicket) return;
			bookingTicket.disableAllScanListeners();
		}),
		enableAllScanListeners: useMemoizedFn(() => {
			if (!bookingTicket) return;
			bookingTicket.enableAllScanListeners();
		}),
		clearAllScanListenersTaskQueue: useMemoizedFn(() => {
			if (!bookingTicket) return;
			bookingTicket.clearAllScanListenersTaskQueue();
		})
	};
};
//#endregion
export { useScanManager as default };
