import { createChangeEvent } from "./utils/formEvents.mjs";
import { c } from "react-compiler-runtime";
import React from "react";
import { UdpSwatchPicker } from "udp-react-stencil-component-library";
//#region src/UI/fluent-web-components/UdpSwatchPicker.tsx
const UdpSwatchPicker$1 = (t0) => {
	const $ = c(13);
	let name;
	let onChange;
	let props;
	let value;
	if ($[0] !== t0) {
		({onChange, name, value, ...props} = t0);
		$[0] = t0;
		$[1] = name;
		$[2] = onChange;
		$[3] = props;
		$[4] = value;
	} else {
		name = $[1];
		onChange = $[2];
		props = $[3];
		value = $[4];
	}
	let t1;
	if ($[5] !== name || $[6] !== onChange) {
		t1 = (e) => {
			onChange?.(createChangeEvent(e.detail, name, "swatch-picker"));
		};
		$[5] = name;
		$[6] = onChange;
		$[7] = t1;
	} else t1 = $[7];
	const handleValueChanged = t1;
	let t2;
	if ($[8] !== handleValueChanged || $[9] !== name || $[10] !== props || $[11] !== value) {
		t2 = /* @__PURE__ */ React.createElement(UdpSwatchPicker, {
			...props,
			name,
			value,
			onValueChanged: handleValueChanged
		});
		$[8] = handleValueChanged;
		$[9] = name;
		$[10] = props;
		$[11] = value;
		$[12] = t2;
	} else t2 = $[12];
	return t2;
};
//#endregion
export { UdpSwatchPicker$1 as UdpSwatchPicker };

//# sourceMappingURL=UdpSwatchPicker.mjs.map