芝麻web文件管理V1.00
编辑当前文件:/home/royashxg/www/wp-content/plugins/blocksy-companion/static/js/editor/blocks/share-box/index.js
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' import deprecated from './deprecated' export const options = getOptionsForBlock('share_box') export const defaultAttributes = getAttributesFromOptions(options) registerBlockType('blocksy/share-box', { apiVersion: 3, title: __('Share Box Controls', 'blocksy-companion'), icon: { src: (
), }, supports: { html: false, inserter: false, lock: false, }, parent: ['blocksy/widgets-wrapper'], attributes: { ...defaultAttributes, ...colorsDefaults, }, edit: (props) =>
, save: function () { return
Blocksy: Share Box
}, deprecated, }) wp.blocks.registerBlockVariation('blocksy/widgets-wrapper', { name: 'blocksy-share-box', title: __('Share Box', 'blocksy-companion'), description: __( 'Share content on social media, boosting visibility & engagement.', 'blocksy-companion' ), attributes: { heading: __('Share Box', 'blocksy-companion'), block: 'blocksy/share-box', }, isActive: (attributes) => attributes.block === 'blocksy/share-box', icon: { src: (
), }, })