import { DeleteOutlined, InfoCircleOutlined } from '@ant-design/icons/lib' import { Button, Card, Form, Input, Popconfirm, Select, Switch } from 'antd' import { FormInstance } from 'antd/lib/form' import { FieldData } from 'rc-field-form/lib/interface' import React, { useState } from 'react' import { Trans, useTranslation } from 'react-i18next' import { FormFieldFragment } from '../../../graphql/fragment/form.fragment' interface Props { form: FormInstance field: FieldData groups: { [key: string]: FormFieldFragment[] } remove: (index: number) => void index: number } export const NotificationCard: React.FC = (props) => { const { t } = useTranslation() const { form, field, remove, index, groups } = props const [enabled, setEnabled] = useState() return ( { remove(index) }} > } actions={[ remove(index)} />]} > setEnabled(e.valueOf())} /> {() => ( )} {() => ( form:notifications.htmlTemplateInfo } labelCol={{ span: 6 }} > )} {() => ( )} {() => ( )} {() => ( )} {() => ( )} ) }