diff --git a/mu-plugins/blocks/modal/src/index.js b/mu-plugins/blocks/modal/src/index.js index 88cd7258..f621fbf2 100644 --- a/mu-plugins/blocks/modal/src/index.js +++ b/mu-plugins/blocks/modal/src/index.js @@ -3,16 +3,19 @@ */ import { __ } from '@wordpress/i18n'; import { + // eslint-disable-next-line @wordpress/no-unsafe-wp-apis -- experimental ok. __experimentalColorGradientSettingsDropdown as ColorGradientSettingsDropdown, - __experimentalUseMultipleOriginColorsAndGradients as useMultipleOriginColorsAndGradients, - InspectorControls, InnerBlocks, + InspectorControls, RichText, useBlockProps, + // eslint-disable-next-line @wordpress/no-unsafe-wp-apis -- experimental ok. + __experimentalUseMultipleOriginColorsAndGradients as useMultipleOriginColorsAndGradients, withColors, } from '@wordpress/block-editor'; import { PanelBody, TextControl, ToggleControl } from '@wordpress/components'; import { registerBlockType } from '@wordpress/blocks'; +// eslint-disable-next-line import/no-extraneous-dependencies import { useState } from 'react'; /** @@ -56,10 +59,10 @@ function Edit( { ? `var( --wp--preset--color--${ overlayColor.slug } )` : customOverlayColor, }; - console.log( style ); + const blockProps = useBlockProps( { className: classes, - style, + style: style, } ); return ( diff --git a/mu-plugins/blocks/modal/src/view.js b/mu-plugins/blocks/modal/src/view.js index 5d242653..1514d608 100644 --- a/mu-plugins/blocks/modal/src/view.js +++ b/mu-plugins/blocks/modal/src/view.js @@ -29,7 +29,7 @@ const { actions } = store( 'wporg/modal', { * Close the modal only if the backdrop is clicked. * Ignores clicks inside the modal itself. * - * @param {Event} event + * @param {Event} event */ clickBackdrop: ( event ) => { if ( event.target.classList.contains( 'wporg-modal__modal-backdrop' ) ) {