const require_runtime = require("../../../_virtual/_rolldown/runtime.js");
const require_index = require("../../../locales/index.js");
const require_index$1 = require("../../pisellScan/index.js");
let react = require("react");
react = require_runtime.__toESM(react);
require("./index.less");
//#region src/components/pisellInformationEntry/Scan/index.tsx
const Scan = (props) => {
	const { onChange, onCancel } = props;
	const scanRef = (0, react.useRef)(null);
	return /* @__PURE__ */ react.default.createElement(require_index$1.default, {
		width: "100%",
		height: "200px",
		borderRadius: "12px",
		onChange,
		timeBetweenScansMillis: 1e3,
		ref: scanRef
	}, /* @__PURE__ */ react.default.createElement("div", { className: "pisell-scan-custom-action" }, /* @__PURE__ */ react.default.createElement("span", { onClick: () => {
		var _scanRef$current;
		(_scanRef$current = scanRef.current) === null || _scanRef$current === void 0 || (_scanRef$current = _scanRef$current.codeReader) === null || _scanRef$current === void 0 || _scanRef$current.reset();
		onCancel();
	} }, require_index.getText("pisell-information-entry-scan-exit"))));
};
//#endregion
exports.default = Scan;
