From 7a496a420ab4a538641011af7d424c57c2640a38 Mon Sep 17 00:00:00 2001 From: Lena Morita Date: Fri, 19 Aug 2022 02:08:42 +0900 Subject: [PATCH] Pass through additional className --- .../text-decoration-control/index.js | 24 +++++++++++++++---- 1 file changed, 19 insertions(+), 5 deletions(-) diff --git a/packages/block-editor/src/components/text-decoration-control/index.js b/packages/block-editor/src/components/text-decoration-control/index.js index 170ff9bf441f72..44635602c947a5 100644 --- a/packages/block-editor/src/components/text-decoration-control/index.js +++ b/packages/block-editor/src/components/text-decoration-control/index.js @@ -1,3 +1,8 @@ +/** + * External dependencies + */ +import classnames from 'classnames'; + /** * WordPress dependencies */ @@ -24,17 +29,26 @@ const TEXT_DECORATIONS = [ /** * Control to facilitate text decoration selections. * - * @param {Object} props Component props. - * @param {string} props.value Currently selected text decoration. - * @param {Function} props.onChange Handles change in text decoration selection. + * @param {Object} props Component props. + * @param {string} props.value Currently selected text decoration. + * @param {Function} props.onChange Handles change in text decoration selection. + * @param {string} [props.className] Additional class name to apply. * * @return {WPElement} Text decoration control. */ -export default function TextDecorationControl( { value, onChange, ...props } ) { +export default function TextDecorationControl( { + value, + onChange, + className, + ...props +} ) { return (