Loading core/modules/media/css/oembed.formatter.css +2 −0 Original line number Diff line number Diff line .media-oembed-content { max-width: 100%; border: none; background-color: transparent; } core/modules/media/src/Plugin/Field/FieldFormatter/OEmbedFormatter.php +0 −3 Original line number Diff line number Diff line Loading @@ -22,7 +22,6 @@ use Drupal\media\Plugin\media\Source\OEmbedInterface; use Symfony\Component\DependencyInjection\ContainerInterface; // cspell:ignore allowtransparency /** * Plugin implementation of the 'oembed' formatter. * Loading Loading @@ -227,9 +226,7 @@ public function viewElements(FieldItemListInterface $items, $langcode) { '#tag' => 'iframe', '#attributes' => [ 'src' => $url->toString(), 'frameborder' => 0, 'scrolling' => FALSE, 'allowtransparency' => TRUE, // External service is not supposed to send something larger // than the max width or max height, so those values should be used. 'width' => $resource->getWidth() ?: $max_width, Loading core/modules/media/tests/src/Functional/FieldFormatter/OEmbedFormatterTest.php +3 −0 Original line number Diff line number Diff line Loading @@ -72,6 +72,9 @@ public static function providerRender() { 'height' => '360', 'title' => 'Drupal Rap Video - Schipulcon09', 'loading' => 'lazy', // cSpell:disable-next-line 'allowtransparency' => NULL, 'frameborder' => NULL, ], ], 'self_closing' => TRUE, Loading core/themes/stable9/css/media/oembed.formatter.css +2 −0 Original line number Diff line number Diff line .media-oembed-content { max-width: 100%; border: none; background-color: transparent; } Loading
core/modules/media/css/oembed.formatter.css +2 −0 Original line number Diff line number Diff line .media-oembed-content { max-width: 100%; border: none; background-color: transparent; }
core/modules/media/src/Plugin/Field/FieldFormatter/OEmbedFormatter.php +0 −3 Original line number Diff line number Diff line Loading @@ -22,7 +22,6 @@ use Drupal\media\Plugin\media\Source\OEmbedInterface; use Symfony\Component\DependencyInjection\ContainerInterface; // cspell:ignore allowtransparency /** * Plugin implementation of the 'oembed' formatter. * Loading Loading @@ -227,9 +226,7 @@ public function viewElements(FieldItemListInterface $items, $langcode) { '#tag' => 'iframe', '#attributes' => [ 'src' => $url->toString(), 'frameborder' => 0, 'scrolling' => FALSE, 'allowtransparency' => TRUE, // External service is not supposed to send something larger // than the max width or max height, so those values should be used. 'width' => $resource->getWidth() ?: $max_width, Loading
core/modules/media/tests/src/Functional/FieldFormatter/OEmbedFormatterTest.php +3 −0 Original line number Diff line number Diff line Loading @@ -72,6 +72,9 @@ public static function providerRender() { 'height' => '360', 'title' => 'Drupal Rap Video - Schipulcon09', 'loading' => 'lazy', // cSpell:disable-next-line 'allowtransparency' => NULL, 'frameborder' => NULL, ], ], 'self_closing' => TRUE, Loading
core/themes/stable9/css/media/oembed.formatter.css +2 −0 Original line number Diff line number Diff line .media-oembed-content { max-width: 100%; border: none; background-color: transparent; }