import omit from "lodash/omit.js";
import { ImageProps } from "../../components/Image/schema.js";
import { YandexFormProps } from "../../components/YandexForm/schema.js";
import { BlockBaseProps, withTheme } from "../../gravity-blocks/schema/validators/common.js";
import { ContentBase } from "../../sub-blocks/Content/schema.js";
import { HubspotFormProps } from "../../sub-blocks/HubspotForm/schema.js";
const FormBlockContentProps = omit(ContentBase, ['size', 'centered', 'colSizes']);
export const FormBlock = {
    'form-block': {
        additionalProperties: false,
        required: ['formData'],
        properties: {
            ...BlockBaseProps,
            title: {
                type: 'string',
            },
            formData: {
                oneOf: [
                    {
                        type: 'object',
                        optionName: 'yandex',
                        properties: {
                            yandex: withTheme(YandexFormProps),
                        },
                    },
                    {
                        type: 'object',
                        optionName: 'hubspot',
                        properties: {
                            hubspot: withTheme(HubspotFormProps),
                        },
                    },
                ],
            },
            textContent: {
                additionalProperties: false,
                properties: FormBlockContentProps,
            },
            direction: {
                enum: ['content-form', 'form-content', 'center'],
            },
            background: ImageProps,
        },
    },
};
//# sourceMappingURL=schema.js.map
