diff --git a/packages/block-library/src/editor.scss b/packages/block-library/src/editor.scss
index 58c8803144a31..31c6eccaf829c 100644
--- a/packages/block-library/src/editor.scss
+++ b/packages/block-library/src/editor.scss
@@ -14,6 +14,7 @@
@import "./image/editor.scss";
@import "./latest-comments/editor.scss";
@import "./latest-posts/editor.scss";
+@import "./media-text/editor.scss";
@import "./list/editor.scss";
@import "./more/editor.scss";
@import "./nextpage/editor.scss";
diff --git a/packages/block-library/src/index.js b/packages/block-library/src/index.js
index 01644d7bd20d6..ecb354f8c373e 100644
--- a/packages/block-library/src/index.js
+++ b/packages/block-library/src/index.js
@@ -28,6 +28,7 @@ import * as cover from './cover';
import * as embed from './embed';
import * as file from './file';
import * as html from './html';
+import * as mediaText from './media-text';
import * as latestComments from './latest-comments';
import * as latestPosts from './latest-posts';
import * as list from './list';
@@ -76,6 +77,7 @@ export const registerCoreBlocks = () => {
file,
window.wp && window.wp.oldEditor ? classic : null, // Only add the classic block in WP Context
html,
+ mediaText,
latestComments,
latestPosts,
missing,
diff --git a/packages/block-library/src/media-text/edit.js b/packages/block-library/src/media-text/edit.js
new file mode 100644
index 0000000000000..7570b2cc7b053
--- /dev/null
+++ b/packages/block-library/src/media-text/edit.js
@@ -0,0 +1,163 @@
+/**
+ * External dependencies
+ */
+import classnames from 'classnames';
+
+/**
+ * WordPress dependencies
+ */
+import { __ } from '@wordpress/i18n';
+import {
+ BlockControls,
+ InnerBlocks,
+ InspectorControls,
+ PanelColorSettings,
+ withColors,
+} from '@wordpress/editor';
+import { Component, Fragment } from '@wordpress/element';
+import { Toolbar } from '@wordpress/components';
+
+/**
+ * Internal dependencies
+ */
+import MediaContainer from './media-container';
+
+/**
+ * Constants
+ */
+const ALLOWED_BLOCKS = [ 'core/button', 'core/paragraph', 'core/heading', 'core/list' ];
+const TEMPLATE = [
+ [ 'core/paragraph', { fontSize: 'large', placeholder: 'Content…' } ],
+];
+
+class MediaTextEdit extends Component {
+ constructor() {
+ super( ...arguments );
+
+ this.onSelectMedia = this.onSelectMedia.bind( this );
+ this.onWidthChange = this.onWidthChange.bind( this );
+ this.commitWidthChange = this.commitWidthChange.bind( this );
+ this.state = {
+ mediaWidth: null,
+ };
+ }
+
+ onSelectMedia( media ) {
+ const { setAttributes } = this.props;
+
+ let mediaType;
+ // for media selections originated from a file upload.
+ if ( media.media_type ) {
+ if ( media.media_type === 'image' ) {
+ mediaType = 'image';
+ } else {
+ // only images and videos are accepted so if the media_type is not an image we can assume it is a video.
+ // video contain the media type of 'file' in the object returned from the rest api.
+ mediaType = 'video';
+ }
+ } else { // for media selections originated from existing files in the media library.
+ mediaType = media.type;
+ }
+
+ setAttributes( {
+ mediaAlt: media.alt,
+ mediaId: media.id,
+ mediaType,
+ mediaUrl: media.url,
+ } );
+ }
+
+ onWidthChange( width ) {
+ this.setState( {
+ mediaWidth: width,
+ } );
+ }
+
+ commitWidthChange( width ) {
+ const { setAttributes } = this.props;
+
+ setAttributes( {
+ mediaWidth: width,
+ } );
+ this.setState( {
+ mediaWidth: null,
+ } );
+ }
+
+ renderMediaArea() {
+ const { attributes } = this.props;
+ const { mediaAlt, mediaId, mediaPosition, mediaType, mediaUrl, mediaWidth } = attributes;
+
+ return (
+
+ );
+ }
+
+ render() {
+ const {
+ attributes,
+ className,
+ backgroundColor,
+ setAttributes,
+ setBackgroundColor,
+ } = this.props;
+ const { mediaPosition, mediaWidth } = attributes;
+ const temporaryMediaWidth = this.state.mediaWidth;
+ const classNames = classnames( className, {
+ 'has-media-on-the-right': 'right' === mediaPosition,
+ [ backgroundColor.class ]: backgroundColor.class,
+ } );
+ const widthString = `${ temporaryMediaWidth || mediaWidth }%`;
+ const style = {
+ gridTemplateColumns: 'right' === mediaPosition ? `auto ${ widthString }` : `${ widthString } auto`,
+ backgroundColor: backgroundColor.color,
+ };
+ const colorSettings = [ {
+ value: backgroundColor.color,
+ onChange: setBackgroundColor,
+ label: __( 'Background Color' ),
+ } ];
+ const toolbarControls = [ {
+ icon: 'align-pull-left',
+ title: __( 'Show media on left' ),
+ isActive: mediaPosition === 'left',
+ onClick: () => setAttributes( { mediaPosition: 'left' } ),
+ }, {
+ icon: 'align-pull-right',
+ title: __( 'Show media on right' ),
+ isActive: mediaPosition === 'right',
+ onClick: () => setAttributes( { mediaPosition: 'right' } ),
+ } ];
+ return (
+
+
+
+
+
+
+
+
+ { this.renderMediaArea() }
+
+
+
+ );
+ }
+}
+
+export default withColors( 'backgroundColor' )( MediaTextEdit );
diff --git a/packages/block-library/src/media-text/editor.scss b/packages/block-library/src/media-text/editor.scss
new file mode 100644
index 0000000000000..b0eccc5aace15
--- /dev/null
+++ b/packages/block-library/src/media-text/editor.scss
@@ -0,0 +1,59 @@
+.wp-block-media-text,
+.wp-block-media-text.aligncenter {
+ grid-template-areas:
+ "media-text-media media-text-content"
+ "resizer resizer";
+}
+
+.wp-block-media-text.has-media-on-the-right,
+.wp-block-media-text.has-media-on-the-right.aligncenter {
+ grid-template-areas:
+ "media-text-content media-text-media"
+ "resizer resizer";
+}
+
+.wp-block-media-text .__resizable_base__ {
+ grid-area: resizer;
+}
+
+.wp-block-media-text .editor-media-container__resizer {
+ grid-area: media-text-media;
+ align-self: center;
+ // The resizer sets a inline width but as we are using a grid layout,
+ // we set the width on container.
+ width: 100% !important;
+}
+
+.wp-block-media-text .editor-inner-blocks {
+ word-break: break-word;
+ grid-area: media-text-content;
+ text-align: initial;
+ padding: 0 8% 0 8%;
+}
+
+.wp-block-media-text > .editor-inner-blocks > .editor-block-list__layout > .editor-block-list__block {
+ max-width: unset;
+}
+
+figure.block-library-media-text__media-container {
+ margin: 0;
+ height: 100%;
+ width: 100%;
+}
+
+.wp-block-media-text .block-library-media-text__media-container img,
+.wp-block-media-text .block-library-media-text__media-container video {
+ margin-bottom: -8px;
+ width: 100%;
+}
+
+.editor-media-container__resizer .components-resizable-box__handle {
+ display: none;
+}
+
+.editor-block-list__block.is-selected,
+.editor-block-list__block.is-focused {
+ .editor-media-container__resizer .components-resizable-box__handle {
+ display: block;
+ }
+}
diff --git a/packages/block-library/src/media-text/index.js b/packages/block-library/src/media-text/index.js
new file mode 100644
index 0000000000000..ed08b7b551c29
--- /dev/null
+++ b/packages/block-library/src/media-text/index.js
@@ -0,0 +1,120 @@
+/**
+ * External dependencies
+ */
+import { noop } from 'lodash';
+import classnames from 'classnames';
+
+/**
+ * WordPress dependencies
+ */
+import { __ } from '@wordpress/i18n';
+import {
+ InnerBlocks,
+ getColorClassName,
+} from '@wordpress/editor';
+
+/**
+ * Internal dependencies
+ */
+import edit from './edit';
+
+const DEFAULT_MEDIA_WIDTH = 50;
+
+export const name = 'core/media-text';
+
+export const settings = {
+ title: __( 'Media & Text' ),
+
+ icon: ,
+
+ category: 'layout',
+
+ keywords: [ __( 'image' ), __( 'video' ), __( 'half' ) ],
+
+ attributes: {
+ align: {
+ type: 'string',
+ default: 'wide',
+ },
+ backgroundColor: {
+ type: 'string',
+ },
+ customBackgroundColor: {
+ type: 'string',
+ },
+ mediaAlt: {
+ type: 'string',
+ source: 'attribute',
+ selector: 'figure img',
+ attribute: 'alt',
+ default: '',
+ },
+ mediaPosition: {
+ type: 'string',
+ default: 'left',
+ },
+ mediaId: {
+ type: 'number',
+ },
+ mediaUrl: {
+ type: 'string',
+ source: 'attribute',
+ selector: 'figure video,figure img',
+ attribute: 'src',
+ },
+ mediaType: {
+ type: 'string',
+ },
+ mediaWidth: {
+ type: 'number',
+ default: 50,
+ },
+ },
+
+ supports: {
+ align: [ 'wide', 'full' ],
+ },
+
+ edit,
+
+ save( { attributes } ) {
+ const {
+ backgroundColor,
+ customBackgroundColor,
+ mediaAlt,
+ mediaPosition,
+ mediaType,
+ mediaUrl,
+ mediaWidth,
+ } = attributes;
+ const mediaTypeRenders = {
+ image: () => ,
+ video: () => ,
+ };
+
+ const backgroundClass = getColorClassName( 'background-color', backgroundColor );
+ const className = classnames( {
+ 'has-media-on-the-right': 'right' === mediaPosition,
+ [ backgroundClass ]: backgroundClass,
+ } );
+
+ let gridTemplateColumns;
+ if ( mediaWidth !== DEFAULT_MEDIA_WIDTH ) {
+ gridTemplateColumns = 'right' === mediaPosition ? `auto ${ mediaWidth }%` : `${ mediaWidth }% auto`;
+ }
+ const style = {
+ backgroundColor: backgroundClass ? undefined : customBackgroundColor,
+ gridTemplateColumns,
+ };
+ return (
+
+
+
+
+
+
+ );
+ },
+};
diff --git a/packages/block-library/src/media-text/media-container.js b/packages/block-library/src/media-text/media-container.js
new file mode 100644
index 0000000000000..f2c7920ba71f0
--- /dev/null
+++ b/packages/block-library/src/media-text/media-container.js
@@ -0,0 +1,125 @@
+/**
+ * WordPress dependencies
+ */
+import { __ } from '@wordpress/i18n';
+import { Component, Fragment } from '@wordpress/element';
+import { IconButton, ResizableBox, Toolbar } from '@wordpress/components';
+import {
+ BlockControls,
+ MediaPlaceholder,
+ MediaUpload,
+} from '@wordpress/editor';
+
+/**
+ * Constants
+ */
+const ALLOWED_MEDIA_TYPES = [ 'image', 'video' ];
+
+class MediaContainer extends Component {
+ renderToolbarEditButton() {
+ const { mediaId, onSelectMedia } = this.props;
+ return (
+
+
+ (
+
+ ) }
+ />
+
+
+ );
+ }
+
+ renderImage() {
+ const { mediaAlt, mediaUrl, className } = this.props;
+ return (
+
+ { this.renderToolbarEditButton() }
+
+
+ );
+ }
+
+ renderVideo() {
+ const { mediaUrl, className } = this.props;
+ return (
+
+ { this.renderToolbarEditButton() }
+
+
+ );
+ }
+
+ renderPlaceholder() {
+ const { onSelectMedia, className } = this.props;
+ return (
+
+ );
+ }
+
+ render() {
+ const { mediaPosition, mediaUrl, mediaType, mediaWidth, commitWidthChange, onWidthChange } = this.props;
+ if ( mediaType && mediaUrl ) {
+ const onResize = ( event, direction, elt ) => {
+ onWidthChange( parseInt( elt.style.width ) );
+ };
+ const onResizeStop = ( event, direction, elt ) => {
+ commitWidthChange( parseInt( elt.style.width ) );
+ };
+ const enablePositions = {
+ right: mediaPosition === 'left',
+ left: mediaPosition === 'right',
+ };
+
+ let mediaElement = null;
+ switch ( mediaType ) {
+ case 'image':
+ mediaElement = this.renderImage();
+ break;
+ case 'video':
+ mediaElement = this.renderVideo();
+ break;
+ }
+ return (
+
+ { mediaElement }
+
+ );
+ }
+ return this.renderPlaceholder();
+ }
+}
+
+export default MediaContainer;
diff --git a/packages/block-library/src/media-text/style.scss b/packages/block-library/src/media-text/style.scss
new file mode 100644
index 0000000000000..86e64b4bd27b1
--- /dev/null
+++ b/packages/block-library/src/media-text/style.scss
@@ -0,0 +1,35 @@
+.wp-block-media-text,
+.wp-block-media-text.aligncenter {
+ display: grid;
+}
+
+.wp-block-media-text {
+ grid-template-rows: auto;
+ grid-template-areas: "media-text-media media-text-content";
+ align-items: center;
+ grid-template-columns: 50% auto;
+ .has-media-on-the-right {
+ grid-template-columns: auto 50%;
+ }
+}
+
+.wp-block-media-text .wp-block-media-text__media {
+ grid-area: media-text-media;
+ margin: 0;
+}
+
+.wp-block-media-text .wp-block-media-text__content {
+ word-break: break-word;
+ grid-area: media-text-content;
+ padding: 0 8% 0 8%;
+}
+.wp-block-media-text.has-media-on-the-right {
+ grid-template-areas: "media-text-content media-text-media";
+}
+
+.wp-block-media-text > figure > img,
+.wp-block-media-text > figure > video {
+ max-width: unset;
+ width: 100%;
+ margin-bottom: -6px;
+}
diff --git a/packages/block-library/src/style.scss b/packages/block-library/src/style.scss
index 0d18fe6895497..45618cc406b11 100644
--- a/packages/block-library/src/style.scss
+++ b/packages/block-library/src/style.scss
@@ -11,6 +11,7 @@
@import "./image/style.scss";
@import "./latest-comments/style.scss";
@import "./latest-posts/style.scss";
+@import "./media-text/style.scss";
@import "./paragraph/style.scss";
@import "./pullquote/style.scss";
@import "./quote/style.scss";
diff --git a/test/integration/full-content/fixtures/core__media-text.html b/test/integration/full-content/fixtures/core__media-text.html
new file mode 100644
index 0000000000000..63d279b9db438
--- /dev/null
+++ b/test/integration/full-content/fixtures/core__media-text.html
@@ -0,0 +1,12 @@
+
+
+
+
+
+
diff --git a/test/integration/full-content/fixtures/core__media-text.json b/test/integration/full-content/fixtures/core__media-text.json
new file mode 100644
index 0000000000000..a4f26e4c9a5c5
--- /dev/null
+++ b/test/integration/full-content/fixtures/core__media-text.json
@@ -0,0 +1,32 @@
+[
+ {
+ "clientId": "_clientId_0",
+ "name": "core/media-text",
+ "isValid": true,
+ "attributes": {
+ "align": "wide",
+ "mediaAlt": "",
+ "mediaPosition": "left",
+ "mediaId": 17985,
+ "mediaUrl": "http://localhost/wp-content/uploads/2018/09/1600px-Mount_Everest_as_seen_from_Drukair2_PLW_edit.jpg",
+ "mediaType": "image",
+ "mediaWidth": 50
+ },
+ "innerBlocks": [
+ {
+ "clientId": "_clientId_0",
+ "name": "core/paragraph",
+ "isValid": true,
+ "attributes": {
+ "content": "My Content",
+ "dropCap": false,
+ "placeholder": "Content…",
+ "fontSize": "large"
+ },
+ "innerBlocks": [],
+ "originalContent": "My Content
"
+ }
+ ],
+ "originalContent": "\n\t
\n\t
\n\t\t\n\t
\n
"
+ }
+]
diff --git a/test/integration/full-content/fixtures/core__media-text.parsed.json b/test/integration/full-content/fixtures/core__media-text.parsed.json
new file mode 100644
index 0000000000000..82df709985669
--- /dev/null
+++ b/test/integration/full-content/fixtures/core__media-text.parsed.json
@@ -0,0 +1,27 @@
+[
+ {
+ "blockName": "core/media-text",
+ "attrs": {
+ "mediaId": 17985,
+ "mediaType": "image"
+ },
+ "innerBlocks": [
+ {
+ "blockName": "core/paragraph",
+ "attrs": {
+ "placeholder": "Content…",
+ "fontSize": "large"
+ },
+ "innerBlocks": [],
+ "innerHTML": "\n\t\tMy Content
\n\t\t"
+ }
+ ],
+ "innerHTML": "\n\n\t
\n\t
\n\t\t\n\t
\n
\n"
+ },
+ {
+ "blockName": null,
+ "attrs": {},
+ "innerBlocks": [],
+ "innerHTML": "\n"
+ }
+]
diff --git a/test/integration/full-content/fixtures/core__media-text.serialized.html b/test/integration/full-content/fixtures/core__media-text.serialized.html
new file mode 100644
index 0000000000000..5e70ba8e96eaa
--- /dev/null
+++ b/test/integration/full-content/fixtures/core__media-text.serialized.html
@@ -0,0 +1,5 @@
+
+
+
diff --git a/test/integration/full-content/fixtures/core__media-text__image-alt-no-align.html b/test/integration/full-content/fixtures/core__media-text__image-alt-no-align.html
new file mode 100644
index 0000000000000..66e424e3b148a
--- /dev/null
+++ b/test/integration/full-content/fixtures/core__media-text__image-alt-no-align.html
@@ -0,0 +1,12 @@
+
+
+
+
+
+
diff --git a/test/integration/full-content/fixtures/core__media-text__image-alt-no-align.json b/test/integration/full-content/fixtures/core__media-text__image-alt-no-align.json
new file mode 100644
index 0000000000000..d8f8ffa431fa6
--- /dev/null
+++ b/test/integration/full-content/fixtures/core__media-text__image-alt-no-align.json
@@ -0,0 +1,32 @@
+[
+ {
+ "clientId": "_clientId_0",
+ "name": "core/media-text",
+ "isValid": true,
+ "attributes": {
+ "align": "none",
+ "mediaAlt": "my alt",
+ "mediaPosition": "left",
+ "mediaId": 17985,
+ "mediaUrl": "http://localhost/wp-content/uploads/2018/09/1600px-Mount_Everest_as_seen_from_Drukair2_PLW_edit.jpg",
+ "mediaType": "image",
+ "mediaWidth": 50
+ },
+ "innerBlocks": [
+ {
+ "clientId": "_clientId_0",
+ "name": "core/paragraph",
+ "isValid": true,
+ "attributes": {
+ "content": "Content",
+ "dropCap": false,
+ "placeholder": "Content…",
+ "fontSize": "large"
+ },
+ "innerBlocks": [],
+ "originalContent": "Content
"
+ }
+ ],
+ "originalContent": "\n\t
\n\t
\n\t\t\n\t
\n
"
+ }
+]
diff --git a/test/integration/full-content/fixtures/core__media-text__image-alt-no-align.parsed.json b/test/integration/full-content/fixtures/core__media-text__image-alt-no-align.parsed.json
new file mode 100644
index 0000000000000..5e9fc5b3f5e1e
--- /dev/null
+++ b/test/integration/full-content/fixtures/core__media-text__image-alt-no-align.parsed.json
@@ -0,0 +1,28 @@
+[
+ {
+ "blockName": "core/media-text",
+ "attrs": {
+ "align": "none",
+ "mediaId": 17985,
+ "mediaType": "image"
+ },
+ "innerBlocks": [
+ {
+ "blockName": "core/paragraph",
+ "attrs": {
+ "placeholder": "Content…",
+ "fontSize": "large"
+ },
+ "innerBlocks": [],
+ "innerHTML": "\n\t\tContent
\n\t\t"
+ }
+ ],
+ "innerHTML": "\n\n\t
\n\t
\n\t\t\n\t
\n
\n"
+ },
+ {
+ "blockName": null,
+ "attrs": {},
+ "innerBlocks": [],
+ "innerHTML": "\n"
+ }
+]
diff --git a/test/integration/full-content/fixtures/core__media-text__image-alt-no-align.serialized.html b/test/integration/full-content/fixtures/core__media-text__image-alt-no-align.serialized.html
new file mode 100644
index 0000000000000..3a28587c29baf
--- /dev/null
+++ b/test/integration/full-content/fixtures/core__media-text__image-alt-no-align.serialized.html
@@ -0,0 +1,5 @@
+
+
+
diff --git a/test/integration/full-content/fixtures/core__media-text__media-right-custom-width.html b/test/integration/full-content/fixtures/core__media-text__media-right-custom-width.html
new file mode 100644
index 0000000000000..b0772fb7b44d9
--- /dev/null
+++ b/test/integration/full-content/fixtures/core__media-text__media-right-custom-width.html
@@ -0,0 +1,12 @@
+
+
+
diff --git a/test/integration/full-content/fixtures/core__media-text__media-right-custom-width.json b/test/integration/full-content/fixtures/core__media-text__media-right-custom-width.json
new file mode 100644
index 0000000000000..7fadb222f20e5
--- /dev/null
+++ b/test/integration/full-content/fixtures/core__media-text__media-right-custom-width.json
@@ -0,0 +1,33 @@
+[
+ {
+ "clientId": "_clientId_0",
+ "name": "core/media-text",
+ "isValid": true,
+ "attributes": {
+ "align": "full",
+ "mediaAlt": "",
+ "mediaPosition": "right",
+ "mediaId": 17897,
+ "mediaUrl": "http://localhost/wp-content/uploads/2018/09/Jul-26-2018-11-34-54.mp4",
+ "mediaType": "video",
+ "mediaWidth": 41
+ },
+ "innerBlocks": [
+ {
+ "clientId": "_clientId_0",
+ "name": "core/paragraph",
+ "isValid": true,
+ "attributes": {
+ "content": "My video",
+ "align": "right",
+ "dropCap": false,
+ "placeholder": "Content…",
+ "fontSize": "large"
+ },
+ "innerBlocks": [],
+ "originalContent": "My video
"
+ }
+ ],
+ "originalContent": "\n\t
\n\t
\n\t\t\n\t
\n
"
+ }
+]
diff --git a/test/integration/full-content/fixtures/core__media-text__media-right-custom-width.parsed.json b/test/integration/full-content/fixtures/core__media-text__media-right-custom-width.parsed.json
new file mode 100644
index 0000000000000..d344565dadc83
--- /dev/null
+++ b/test/integration/full-content/fixtures/core__media-text__media-right-custom-width.parsed.json
@@ -0,0 +1,31 @@
+[
+ {
+ "blockName": "core/media-text",
+ "attrs": {
+ "align": "full",
+ "mediaPosition": "right",
+ "mediaId": 17897,
+ "mediaType": "video",
+ "mediaWidth": 41
+ },
+ "innerBlocks": [
+ {
+ "blockName": "core/paragraph",
+ "attrs": {
+ "align": "right",
+ "placeholder": "Content…",
+ "fontSize": "large"
+ },
+ "innerBlocks": [],
+ "innerHTML": "\n\t\tMy video
\n\t\t"
+ }
+ ],
+ "innerHTML": "\n\n\t
\n\t
\n\t\t\n\t
\n
\n"
+ },
+ {
+ "blockName": null,
+ "attrs": {},
+ "innerBlocks": [],
+ "innerHTML": "\n"
+ }
+]
diff --git a/test/integration/full-content/fixtures/core__media-text__media-right-custom-width.serialized.html b/test/integration/full-content/fixtures/core__media-text__media-right-custom-width.serialized.html
new file mode 100644
index 0000000000000..a11efac920f28
--- /dev/null
+++ b/test/integration/full-content/fixtures/core__media-text__media-right-custom-width.serialized.html
@@ -0,0 +1,5 @@
+
+
+
diff --git a/test/integration/full-content/fixtures/core__media-text__video.html b/test/integration/full-content/fixtures/core__media-text__video.html
new file mode 100644
index 0000000000000..48c13cac64d08
--- /dev/null
+++ b/test/integration/full-content/fixtures/core__media-text__video.html
@@ -0,0 +1,12 @@
+
+
+
diff --git a/test/integration/full-content/fixtures/core__media-text__video.json b/test/integration/full-content/fixtures/core__media-text__video.json
new file mode 100644
index 0000000000000..4296ee2ae4bb6
--- /dev/null
+++ b/test/integration/full-content/fixtures/core__media-text__video.json
@@ -0,0 +1,32 @@
+[
+ {
+ "clientId": "_clientId_0",
+ "name": "core/media-text",
+ "isValid": true,
+ "attributes": {
+ "align": "wide",
+ "mediaAlt": "",
+ "mediaPosition": "left",
+ "mediaId": 17897,
+ "mediaUrl": "http://localhost/wp-content/uploads/2018/09/Jul-26-2018-11-34-54.mp4",
+ "mediaType": "video",
+ "mediaWidth": 50
+ },
+ "innerBlocks": [
+ {
+ "clientId": "_clientId_0",
+ "name": "core/paragraph",
+ "isValid": true,
+ "attributes": {
+ "content": "My Content",
+ "dropCap": false,
+ "placeholder": "Content…",
+ "fontSize": "large"
+ },
+ "innerBlocks": [],
+ "originalContent": "My Content
"
+ }
+ ],
+ "originalContent": "\n\t
\n\t
\n\t\t\n\t
\n
"
+ }
+]
diff --git a/test/integration/full-content/fixtures/core__media-text__video.parsed.json b/test/integration/full-content/fixtures/core__media-text__video.parsed.json
new file mode 100644
index 0000000000000..ff58f6ab6c5fd
--- /dev/null
+++ b/test/integration/full-content/fixtures/core__media-text__video.parsed.json
@@ -0,0 +1,27 @@
+[
+ {
+ "blockName": "core/media-text",
+ "attrs": {
+ "mediaId": 17897,
+ "mediaType": "video"
+ },
+ "innerBlocks": [
+ {
+ "blockName": "core/paragraph",
+ "attrs": {
+ "placeholder": "Content…",
+ "fontSize": "large"
+ },
+ "innerBlocks": [],
+ "innerHTML": "\n\t\tMy Content
\n\t\t"
+ }
+ ],
+ "innerHTML": "\n\n\t
\n\t
\n\t\t\n\t
\n
\n"
+ },
+ {
+ "blockName": null,
+ "attrs": {},
+ "innerBlocks": [],
+ "innerHTML": "\n"
+ }
+]
diff --git a/test/integration/full-content/fixtures/core__media-text__video.serialized.html b/test/integration/full-content/fixtures/core__media-text__video.serialized.html
new file mode 100644
index 0000000000000..f7302c9a33c5d
--- /dev/null
+++ b/test/integration/full-content/fixtures/core__media-text__video.serialized.html
@@ -0,0 +1,5 @@
+
+
+