import { isRecord as n } from "../../../isRecord.js";
import { resolveFieldInputLabel as l } from "../../../resolveFieldInputLabel/resolveFieldInputLabel.js";
function f(t, o) {
  const i = l(t, o), r = t.fieldType.rhfComponentProps;
  if (!n(r))
    return { resolvedLabel: i };
  const e = {};
  return typeof r.id == "string" && r.id.trim() !== "" && (e.id = r.id.trim()), typeof r.htmlFor == "string" && r.htmlFor.trim() !== "" && (e.htmlFor = r.htmlFor.trim()), typeof r.inlineText == "string" && r.inlineText.trim() !== "" && (e.inlineText = r.inlineText.trim()), typeof r.helperText == "string" && r.helperText.trim() !== "" && (e.helperText = r.helperText.trim()), typeof r.error == "boolean" && (e.error = r.error), {
    ...e,
    resolvedLabel: i
  };
}
export {
  f as normalizeCheckboxPropsFromBackend
};
