芝麻web文件管理V1.00
编辑当前文件:/home/royashxg/www/wp-content/plugins/blocksy-companion/static/js/editor/blocks/about-me/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' export const options = getOptionsForBlock('about_me') export const defaultAttributes = getAttributesFromOptions(options) registerBlockType('blocksy/about-me', { apiVersion: 3, title: __('About Me Controls', 'blocksy-companion'), icon: { src: (
), }, supports: { html: false, inserter: false, lock: false, }, parent: ['blocksy/widgets-wrapper'], attributes: { ...defaultAttributes, ...colorsDefaults, }, edit: (props) =>
, save: () =>
Blocksy: About Me
, }) wp.blocks.registerBlockVariation('blocksy/widgets-wrapper', { name: 'blocksy-about-me', title: __('About Me', 'blocksy-companion'), description: __('Showcase your personal information across your website.', 'blocksy-companion'), attributes: { heading: __('About Me', 'blocksy-companion'), block: 'blocksy/about-me', }, isDefault: true, isActive: (attributes) => attributes.block === 'blocksy/about-me', icon: { src: (
), }, })