import { c } from "react-compiler-runtime";
import React, { useState } from "react";
import { Switch } from "@material-ui/core";
//#region src/reminders/CompleteReminderSwitch.jsx
const CompleteReminderSwitch = (props) => {
	const $ = c(10);
	let checked;
	let onChange;
	let otherProps;
	if ($[0] !== props) {
		({checked, onChange, ...otherProps} = props);
		$[0] = props;
		$[1] = checked;
		$[2] = onChange;
		$[3] = otherProps;
	} else {
		checked = $[1];
		onChange = $[2];
		otherProps = $[3];
	}
	const [switchChecked, setSwitchChecked] = useState(checked);
	let t0;
	if ($[4] !== onChange) {
		t0 = (event) => {
			setSwitchChecked(event.target.checked);
			onChange && onChange(event);
		};
		$[4] = onChange;
		$[5] = t0;
	} else t0 = $[5];
	const handleOnChange = t0;
	let t1;
	if ($[6] !== handleOnChange || $[7] !== otherProps || $[8] !== switchChecked) {
		t1 = /* @__PURE__ */ React.createElement(Switch, {
			checked: switchChecked,
			onChange: handleOnChange,
			...otherProps
		});
		$[6] = handleOnChange;
		$[7] = otherProps;
		$[8] = switchChecked;
		$[9] = t1;
	} else t1 = $[9];
	return t1;
};
//#endregion
export { CompleteReminderSwitch };

//# sourceMappingURL=CompleteReminderSwitch.mjs.map