From f93c474d15bf3fde22692ba231729fc3ae60485f Mon Sep 17 00:00:00 2001 From: mxkae Date: Thu, 15 Jun 2023 19:31:11 +0800 Subject: [PATCH] updated return value, fix issue for tablet/mobile --- src/block-components/helpers/size/style.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/block-components/helpers/size/style.js b/src/block-components/helpers/size/style.js index 8b36a343c..1df42a045 100644 --- a/src/block-components/helpers/size/style.js +++ b/src/block-components/helpers/size/style.js @@ -62,9 +62,9 @@ const Styles = props => { attrNameTemplate={ attrNameTemplate } responsive="all" hasUnits="px" - valueCallback={ ( value, getAttribute ) => { - const blockWidth = getAttribute( 'width' ) - return blockWidth ? 'inherit' : '' + valueCallback={ ( value, getAttribute, device ) => { + const blockWidth = getAttribute( 'width', device ) + return blockWidth ? 'inherit' : undefined } } />