import { Tooltip } from 'antd'; import { useField } from 'react-final-form'; import { SchemaFormContext, useSchemaForm } from './context'; import FieldContainer from './FieldContainer'; import InfoBubble from './InfoBubble'; import Label from './Label'; import { FieldProps } from './types'; import { getError } from './utils'; export const FieldHTML = ({ HTMLEditor, ...props }: FieldProps & { HTMLEditor: SchemaFormContext['components']['HTMLEditor']; }) => { const field = useField(props.name); const { 'ui:widget': uiWidget, 'ui:options': uiOptions = {} } = props.schema; if (!HTMLEditor) return null; const hasError = getError(field.meta); return (
); }; const LinkedFielHTML = (props: FieldProps) => { const { components: { HTMLEditor }, } = useSchemaForm(); return ; }; export default LinkedFielHTML;