import { __exportAll } from "../../../_virtual/_rolldown/runtime.mjs";
import { BaseTextPropertyWidget } from "./TextPropertyWidget.mjs";
import { c } from "react-compiler-runtime";
import React from "react";
import { MenuItem } from "@material-ui/core";
//#region src/UI/property/widgets/SelectPropertyWidget.jsx
var SelectPropertyWidget_exports = /* @__PURE__ */ __exportAll({ default: () => SelectPropertyWidget });
/**
* `select` property widget
*
* Outputs a select TextField
*/
const SelectPropertyWidget = (props) => {
	const $ = c(5);
	const { property } = props;
	const { options } = property;
	let t0;
	if ($[0] !== options) {
		t0 = options.map(_temp);
		$[0] = options;
		$[1] = t0;
	} else t0 = $[1];
	let t1;
	if ($[2] !== props || $[3] !== t0) {
		t1 = /* @__PURE__ */ React.createElement(BaseTextPropertyWidget, {
			select: true,
			...props
		}, t0);
		$[2] = props;
		$[3] = t0;
		$[4] = t1;
	} else t1 = $[4];
	return t1;
};
function _temp(option) {
	return /* @__PURE__ */ React.createElement(MenuItem, {
		key: option.value,
		value: option.value
	}, option.label);
}
//#endregion
export { SelectPropertyWidget_exports, SelectPropertyWidget as default };

//# sourceMappingURL=SelectPropertyWidget.mjs.map