import { createElement } from '@wordpress/element'
import { __ } from 'ct-i18n'
import { registerBlockType } from '@wordpress/blocks'
import { getAttributesFromOptions, getOptionsForBlock } from '../../utils'
import Edit from './Edit'
import { colorsDefaults } from './colors'
export const options = getOptionsForBlock('socials')
export const defaultAttributes = getAttributesFromOptions(options)
registerBlockType('blocksy/socials', {
apiVersion: 3,
title: __('Socials Controls', 'blocksy'),
icon: {
src: (
),
},
supports: {
html: false,
inserter: false,
lock: false,
},
parent: ['blocksy/widgets-wrapper'],
attributes: {
...defaultAttributes,
...colorsDefaults,
},
edit: (props) =>