| Server IP : 38.190.208.107 / Your IP : 216.73.216.189 Web Server : nginx/1.28.1 System : Linux ht2026040333114 6.1.0-10-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.37-1 (2023-07-03) x86_64 User : root ( 0) PHP Version : 8.2.28 Disable Function : passthru,exec,system,putenv,chroot,chgrp,chown,shell_exec,popen,proc_open,pcntl_exec,ini_alter,ini_restore,dl,openlog,syslog,readlink,symlink,popepassthru,pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,imap_open,apache_setenv,eval,assert,passthru,system,exec,shell_exec,popen,proc_open MySQL : OFF | cURL : ON | WGET : OFF | Perl : OFF | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : /www/wwwroot/wp.2/wp-content/plugins/blocksy-companion-pro/static/js/editor/blocks/search/ |
Upload File : |
import { createElement } from '@wordpress/element'
import { __ } from 'ct-i18n'
import { registerBlockType } from '@wordpress/blocks'
import { getAttributesFromOptions, getOptionsForBlock } from 'blocksy-options'
export const options = getOptionsForBlock('search')
export const defaultAttributes = getAttributesFromOptions(options)
import { colorsDefaults } from './colors'
import Edit from './Edit'
registerBlockType('blocksy/search', {
apiVersion: 3,
title: __('Advanced Search', 'blocksy-companion'),
description: __(
'Quickly find specific content on your site.',
'blocksy-companion'
),
icon: {
src: (
<svg
xmlns="http://www.w3.org/2000/svg"
viewBox="0 0 24 24"
className="wc-block-editor-components-block-icon">
<path d="m19.7 18.5-3-2.9c1-1.3 1.6-2.8 1.6-4.5 0-3.9-3.2-7.2-7.2-7.2S4 7.2 4 11.2s3.2 7.2 7.2 7.2c1.7 0 3.3-.6 4.5-1.6l3 3c.1.1.3.2.5.2s.4-.1.5-.2c.3-.4.3-1 0-1.3zM5.6 11.2c0-3.1 2.5-5.5 5.5-5.5s5.6 2.4 5.6 5.5-2.5 5.5-5.5 5.5-5.6-2.5-5.6-5.5z" />
</svg>
),
},
category: 'blocksy-blocks',
attributes: {
...defaultAttributes,
...colorsDefaults,
},
supports: {
spacing: {
margin: true,
__experimentalDefaultControls: {
margin: true,
},
},
__experimentalBorder: {
color: false,
radius: true,
width: false,
__experimentalSkipSerialization: true,
__experimentalDefaultControls: {
color: false,
radius: true,
width: false,
},
},
},
edit: (props) => <Edit {...props} />,
save: function () {
return <div>Blocksy: Search Block</div>
},
})