import { _objectSpread2 } from "../../_virtual/_@oxc-project_runtime@0.122.0/helpers/objectSpread2.js";
import Select from "../select/index.js";
import React, { useMemo } from "react";
import classNames from "classnames";
import "./index.less";
//#region src/components/customSelect/index.tsx
const CustomSelect = (props) => {
	const { options: propsOptions, value, onChange, renderItem } = props;
	const options = useMemo(() => {
		return propsOptions.map((option) => _objectSpread2(_objectSpread2({}, option), {}, {
			label: renderItem ? renderItem(option) : option.label,
			value: option.value
		}));
	}, [propsOptions, renderItem]);
	return /* @__PURE__ */ React.createElement(Select, _objectSpread2(_objectSpread2({}, props), {}, {
		className: classNames("pisell-lowcode-custom-select", props.className),
		options,
		value,
		onChange
	}));
};
//#endregion
export { CustomSelect as default };
