import { createElement, Component, createRef, useState, useEffect, useRef, } from '@wordpress/element' import { __, sprintf } from 'ct-i18n' import $ from 'jquery' const NotificationBlocksDrop = ({ initialStatus, url, pluginUrl, pluginLink, }) => { const [pluginStatus, setPluginStatus] = useState('installed') const [isLoading, setIsLoading] = useState(false) const containerEl = useRef(null) useEffect(() => { setPluginStatus(initialStatus) }, []) const dismiss = () => { containerEl.current.closest('.notice').remove() $.ajax(ajaxurl, { type: 'POST', data: { action: 'blocksy_dismissed_blocks_move_notice_handler', }, }) } return (

{__( 'Heads up - soon theme blocks are going to be moved to the Blocksy Companion plugin', 'blocksy' )}

' + __( 'If you where using the theme blocks before, there is no need to worry, just activate the Blocksy Companion plugin and you will have access to those blocks as before.', 'blocksy' ), }} />

{__('Why you need Blocksy Companion?', 'blocksy')}
) } export default NotificationBlocksDrop