import { cx as e } from "../../../theme/tools.js";
import { useUiTranslation as t } from "../../../i18n/useUiTranslation.js";
import { CopyableText as n } from "../../atoms/copyable_text/CopyableText.js";
import { field as r, fullWidth as i, label as a, size as o, value as s } from "./backofficeDetailField.css.js";
import { jsx as c, jsxs as l } from "react/jsx-runtime";
//#region src/backoffice/molecules/backoffice_detail_field/BackofficeDetailField.tsx
var u = ({ className: u, copiedLabel: d, copyLabel: f, copyValue: p, emptyLabel: m, fullWidth: h = !1, label: g, size: _, value: v }) => {
	let { t: y } = t(), b = v;
	(b == null || typeof b == "string" && b.trim() === "") && (b = m ?? y("common.notAvailable", { defaultValue: "N/A" })), p != null && p !== "" && (b = /* @__PURE__ */ c(n, {
		value: p,
		copyValue: p,
		truncate: !1,
		copyLabel: f ?? y("common.actions.copy", { defaultValue: "Copy" }),
		copiedLabel: d ?? y("common.actions.copied", { defaultValue: "Copied" })
	}));
	let x = [
		r,
		o[_],
		u
	];
	return h && x.push(i), /* @__PURE__ */ l("div", {
		className: e(...x),
		children: [/* @__PURE__ */ c("span", {
			className: a,
			children: g
		}), /* @__PURE__ */ c("div", {
			className: s,
			children: b
		})]
	});
};
//#endregion
export { u as BackofficeDetailField, u as default };

//# sourceMappingURL=BackofficeDetailField.js.map