'use client';
import { getTranslation } from '@payloadcms/translations';
import React from 'react';
import { useTranslation } from '../../providers/Translation/index.js';
const baseClass = 'field-description';
const FieldDescription = (props)=>{
    const { className, description, marginPlacement } = props;
    const { i18n } = useTranslation();
    if (description) {
        return /*#__PURE__*/ React.createElement("div", {
            className: [
                baseClass,
                className,
                marginPlacement && `${baseClass}--margin-${marginPlacement}`
            ].filter(Boolean).join(' ')
        }, getTranslation(description, i18n));
    }
    return null;
};
export default FieldDescription;

//# sourceMappingURL=index.js.map