require("../../../_virtual/_rolldown/runtime.js");
const require_objectSpread2 = require("../../../_virtual/_@oxc-project_runtime@0.122.0/helpers/objectSpread2.js");
const require_useLogger = require("../../../hooks/useLogger.js");
let ahooks = require("ahooks");
//#region src/components/checkout/hooks/usePaymentLogger.ts
const usePaymentLogger = () => {
	const logger = require_useLogger.default();
	const addLog = (0, ahooks.useMemoizedFn)((data) => {
		try {
			var _logger$addLog;
			logger === null || logger === void 0 || (_logger$addLog = logger.addLog) === null || _logger$addLog === void 0 || _logger$addLog.call(logger, data);
		} catch (error) {
			console.error("Failed to add payment log:", error);
		}
	});
	return require_objectSpread2._objectSpread2(require_objectSpread2._objectSpread2({}, logger), {}, { addLog });
};
//#endregion
exports.default = usePaymentLogger;
