X-Git-Url: http://www.aleph1.co.uk/gitweb/?a=blobdiff_plain;ds=sidebyside;f=web%2Fmodules%2Fcontrib%2Fparagraphs%2Fsrc%2FParagraphViewBuilder.php;fp=web%2Fmodules%2Fcontrib%2Fparagraphs%2Fsrc%2FParagraphViewBuilder.php;h=0000000000000000000000000000000000000000;hb=059867c3f96750652c80f39e44c442a58c2549ee;hp=1ebc521bde34b66170375b3efb10c9e0bec8c55b;hpb=f8fc16ae6b862bef59baaad5d051dd37b7ff11b2;p=yaffs-website diff --git a/web/modules/contrib/paragraphs/src/ParagraphViewBuilder.php b/web/modules/contrib/paragraphs/src/ParagraphViewBuilder.php deleted file mode 100644 index 1ebc521bd..000000000 --- a/web/modules/contrib/paragraphs/src/ParagraphViewBuilder.php +++ /dev/null @@ -1,44 +0,0 @@ -bundle() . '.' . $build['#view_mode']) ?: EntityViewDisplay::load('paragraph.' . $build['#paragraph']->bundle() . '.default'); - $paragraph_type = $build['#paragraph']->getParagraphType(); - - // In case we use paragraphs type with no fields the EntityViewDisplay - // might not be available yet. - if (!$display) { - $display = EntityViewDisplay::create([ - 'targetEntityType' => 'paragraph', - 'bundle' => $build['#paragraph']->bundle(), - 'mode' => 'default', - 'status' => TRUE, - ]); - } - - foreach ($paragraph_type->getEnabledBehaviorPlugins() as $plugin_id => $plugin_value) { - $plugin_value->view($build_list[$key], $build['#paragraph'], $display, $build['#view_mode']); - } - } - return $build_list; - } - -}