import { n as AnalyticsId } from "./constants2.js";
import { t as getIllustration } from "./utils.js";
import React, { useId } from "react";
import { jsx } from "react/jsx-runtime";
let ViewBoxSize = /* @__PURE__ */ function(ViewBoxSize$1) {
	ViewBoxSize$1["Medium"] = "0 0 512 512";
	ViewBoxSize$1["Small"] = "0 0 200 200";
	return ViewBoxSize$1;
}({});
const Illustration = React.forwardRef((props, ref) => {
	const { illustration, ariaLabel, className = "", size = 512, color = "neutral", testId, ...other } = props;
	const titleId = useId();
	const viewBox = getIllustration({
		size,
		medium: ViewBoxSize.Medium,
		small: ViewBoxSize.Small
	});
	const svgProperties = {
		"data-testid": testId,
		"data-analyticsid": AnalyticsId.Illustration,
		ref,
		className,
		role: ariaLabel ? "img" : "presentation",
		"aria-labelledby": ariaLabel ? titleId : void 0,
		focusable: false,
		"aria-hidden": ariaLabel ? void 0 : true,
		viewBox,
		style: {
			minWidth: size,
			minHeight: size
		},
		width: size,
		height: size,
		fill: color,
		...other
	};
	return React.createElement(illustration, {
		size,
		color,
		svgProperties,
		title: ariaLabel && /* @__PURE__ */ jsx("title", {
			id: titleId,
			children: ariaLabel
		})
	});
});
Illustration.displayName = "Illustration";
var Illustration_default$1 = Illustration;
export { Illustration as n, ViewBoxSize as r, Illustration_default$1 as t };

//# sourceMappingURL=Illustration.js.map