From f3ebcf3750d1aef7c17061d97dfb0129c67fb75e Mon Sep 17 00:00:00 2001 From: Siobhan Bamber Date: Thu, 29 Feb 2024 10:03:51 +0000 Subject: [PATCH] revert: ensure `playsInline` attribute conforms when falling back to core Video block (#36030) * fix: Revert change to playsInline attribute * docs: Add CHANGELOG --- ...obile-revert-playsinline-setting-change-in-core-video | 4 ++++ .../plugins/jetpack/extensions/blocks/videopress/save.js | 9 +-------- 2 files changed, 5 insertions(+), 8 deletions(-) create mode 100644 projects/plugins/jetpack/changelog/rnmobile-revert-playsinline-setting-change-in-core-video diff --git a/projects/plugins/jetpack/changelog/rnmobile-revert-playsinline-setting-change-in-core-video b/projects/plugins/jetpack/changelog/rnmobile-revert-playsinline-setting-change-in-core-video new file mode 100644 index 0000000000000..13222501d05d3 --- /dev/null +++ b/projects/plugins/jetpack/changelog/rnmobile-revert-playsinline-setting-change-in-core-video @@ -0,0 +1,4 @@ +Significance: patch +Type: other + +RNMobile: Revert change to the way playsInline attribute is saved, prevent regression on web. diff --git a/projects/plugins/jetpack/extensions/blocks/videopress/save.js b/projects/plugins/jetpack/extensions/blocks/videopress/save.js index a731b3ea65c29..2c6b81eae8cd0 100644 --- a/projects/plugins/jetpack/extensions/blocks/videopress/save.js +++ b/projects/plugins/jetpack/extensions/blocks/videopress/save.js @@ -42,14 +42,7 @@ const VideoPressSave = CoreVideoSave => props => { * @see https://github.com/WordPress/gutenberg/blob/c5f9bd88125282a0c35f887cc8d835f065893112/packages/editor/src/hooks/generated-class-name.js#L42 * @see https://github.com/Automattic/wp-calypso/pull/30546#issuecomment-463637946 */ - // Rename `playsinline` to `playsInline` to conform the block schema of core Video block. - const { playsinline: videoPressPlayinline, ...restAttributes } = props.attributes; - const coreVideoAttributes = { ...restAttributes, playsInline: playsinline }; - - return CoreVideoSave( { - ...props, - attributes: coreVideoAttributes, - } ); + return CoreVideoSave( props ); } const url = getVideoPressUrl( guid, {