@if($news->images)
@@ -119,6 +95,10 @@
@endif
+ @if($news->podcast)
+ @include('widgets/podcastplayer', ['podcast' => $news->podcast])
+ @endif
+
@if($news->source && $news->source->show)
Bron: {{$news->source->title}}
diff --git a/resources/views/partial/nh_story.blade.php b/resources/views/partial/nh_story.blade.php index d325b421..b3ceab43 100644 --- a/resources/views/partial/nh_story.blade.php +++ b/resources/views/partial/nh_story.blade.php @@ -1,51 +1,51 @@ @foreach($content as $block) - @if($block->type == "headerRichA") - @php($block->image->url = isset($block->image->crops) - ? $block->image->crops->{'16:9'}->{'1600'} - : $block->image->crop) - -
- {{$block->image->title}}
- @if($block->image->author)
-
- @endif
-
- @elseif($block->type == "text")
- {!!$block->text!!}
- @if (preg_match('!/gemist/fragment/([0-9]*)/!', $block->text, $match))
-
- @endif
- @elseif($block->type == "intro")
- {!!strip_tags($block->text)!!}
- @elseif($block->type == "info") - @if(strpos($block->text, "Meer nieuws uit 't Gooi?") === false) -{!!($block->text)!!}
- @endif
- @elseif($block->type == "quote")
- - {!!$block->text!!} - -- @elseif($block->type == "image") - type == "headerRichA") +@php($block->image->url = isset($block->image->crops) +? $block->image->crops->{'16:9'}->{'1600'} +: $block->image->crop) + +
+ {{$block->image->title}}
+ @if($block->image->author)
+
+ @endif
+
+@elseif($block->type == "text")
+{!!$block->text!!}
+@elseif($block->type == "intro")
+{!!strip_tags($block->text)!!}
+@elseif($block->type == "info") +@if(strpos($block->text, "Meer nieuws uit 't Gooi?") === false) +{!!($block->text)!!}
+@endif
+@elseif($block->type == "quote")
++ {!!$block->text!!} + ++@elseif($block->type == "image") +image->imageWide)) - $image = $block->image->imageWide; + $image = $block->image->imageWide; else if(isset($block->image->crop)) - $image = $block->image->crop; + $image = $block->image->crop; else if(isset($block->image->crops) && isset($block->image->crops->{'16:9'})) foreach($block->image->crops->{'16:9'} as $image) break; else if(isset($block->image->imageHigh)) $image = $block->image->imageHigh; else $image = null; ?> - @if($image) - -
- image->title}} © {{$block->image->author}}">
+
+
+
\ No newline at end of file
+ image->caption) && $block->image->caption) {
$sentence[] = '' . $block->image->caption . '';
@@ -57,52 +57,87 @@
}
$sentence = join('|', $sentence);
?>
- {!!$sentence!!}
-
- @endif
- @elseif($block->type == "video" || $block->type == "headerVideo")
- @include('widgets/mediaplayer')
-
+@endif
+@elseif($block->type == "video" || $block->type == "headerVideo")
+@include('widgets/mediaplayer')
+video->images[0]->imageMedia) && $block->video->images[0]->imageMedia) {
$attr = ' poster="' . $block->video->images[0]->imageMedia . '"';
}
?>
-
-
-
-
- @elseif($block->type == "carousel")
-
-
+
+@elseif($block->type == "oembed")
+
+@elseif($block->type == "podcast" && $block->id == $news->podcast?->id)
+@include('widgets/podcastplayer', ['podcast' => $news->podcast])
+ $news->podcast = null; // Avoid adding the player again ?>
+@elseif($block->type == 'article' && count($block->articles))
+
+
+@endif
+@endforeach
\ No newline at end of file
diff --git a/resources/views/widgets/podcastplayer.blade.php b/resources/views/widgets/podcastplayer.blade.php
index 1b31b201..00d1b3ce 100644
--- a/resources/views/widgets/podcastplayer.blade.php
+++ b/resources/views/widgets/podcastplayer.blade.php
@@ -1,61 +1,56 @@
{{ $block->title }}
+
+
+-
+ @foreach($block->articles as $article)
+ $article->published = new \DateTime($article->published) ?>
+
-
+ + @if($article->image) +++ ++ @endif +
+ +
++{!! $article->title !!}
+ + + {{Formatter::relativeDate($article->published)}} om {{$article->published->format('H:i')}} + +
+ @endforeach
+
-@if($podcast == null)
+ @if($podcast == null)
De podcast kan helaas (op dit moment) niet weergegeven worden.
-@else
+ @else
@include('widgets/mediaplayer')
@if ($podcast)
- url . "?auth=" . $podcast->auth);
$popoutUrl = route('luister.podcast') . $podcast->url . '?auth=' . $podcast->auth;
?>
-
+ @endif
+ @endif
+
-
- @endif
-@endif
+ {{$podcast->title}}
-
-
+
+
+ -
-
- - - {{ Formatter::relativeDate($podcast->created) }} - - @if($podcast->program) - - @endif -
+
- {{$podcast->title}}
+
+
-
- -
+
- + + {{ Formatter::relativeDate($podcast->created) }} + + @if($podcast->program) + + @endif +
- @if($podcast->image)
-
-
-
-
- @endif
-
- {{$podcast->image->title}}
-
- {!!$podcast->content!!}
-
+ @if($podcast->image)
+
+
+
+ @endif
+
+ {{$podcast->image->title}}
{!!$podcast->content!!}
+