import React, {
	Fragment,
	ReactElement,
} from 'react';

import {
	ModuleScriptDataProps,
} from '@divi/module';
import { ColorImageAttrs } from './types';


/**
 * Color & Image script data component.
 *
 * @since ??
 *
 * @param {ModuleScriptDataProps<ColorImageAttrs>} props React component props.
 *
 * @returns {ReactElement}
 */
export const ModuleScriptData = ({
	elements,
}: ModuleScriptDataProps<ColorImageAttrs>): ReactElement => (
	<Fragment>
		{elements.scriptData({
			attrName: 'module',
		})}
	</Fragment>
);
