From 13d3f9e3f5345cb6acc4bd23d92230529c5a7fad Mon Sep 17 00:00:00 2001 From: Sebastian Thulin Date: Wed, 2 Oct 2024 12:31:53 +0200 Subject: [PATCH] fix: resolve issue with missing margin. --- source/php/Module/Posts/Posts.php | 3 +++ source/php/Module/Posts/views/features-grid.blade.php | 2 +- source/php/Module/Posts/views/grid.blade.php | 4 ++-- source/php/Module/Posts/views/index.blade.php | 2 +- source/php/Module/Posts/views/partials/post/block.blade.php | 5 +---- source/php/Module/Posts/views/partials/post/card.blade.php | 4 ---- source/php/Module/Posts/views/segment.blade.php | 3 ++- 7 files changed, 10 insertions(+), 13 deletions(-) diff --git a/source/php/Module/Posts/Posts.php b/source/php/Module/Posts/Posts.php index 73fbab0e1..41d69f6c1 100644 --- a/source/php/Module/Posts/Posts.php +++ b/source/php/Module/Posts/Posts.php @@ -5,6 +5,9 @@ use Municipio\Helper\Image as ImageHelper; use Modularity\Module\Posts\Helper\GetArchiveUrl as ArchiveUrlHelper; use Modularity\Module\Posts\Helper\GetPosts as GetPostsHelper; +use Modularity\Integrations\Component\ImageResolver; +use Modularity\Integrations\Component\ImageFocusResolver; +use ComponentLibrary\Integrations\Image\Image as ImageComponentContract; /** * Class Posts diff --git a/source/php/Module/Posts/views/features-grid.blade.php b/source/php/Module/Posts/views/features-grid.blade.php index 12ca63843..2b46bb92e 100644 --- a/source/php/Module/Posts/views/features-grid.blade.php +++ b/source/php/Module/Posts/views/features-grid.blade.php @@ -1,7 +1,7 @@ @includeWhen(!$hideTitle && !empty($postTitle), 'partials.post-title') @includeWhen($preamble, 'partials.preamble') -
@if($posts) @foreach ($posts as $post) diff --git a/source/php/Module/Posts/views/grid.blade.php b/source/php/Module/Posts/views/grid.blade.php index b02769e2f..4b7f1b73a 100644 --- a/source/php/Module/Posts/views/grid.blade.php +++ b/source/php/Module/Posts/views/grid.blade.php @@ -1,7 +1,7 @@ @includeWhen(!$hideTitle && !empty($postTitle), 'partials.post-title') @includeWhen($preamble, 'partials.preamble') - -
@if($posts) @foreach ($posts as $post) diff --git a/source/php/Module/Posts/views/index.blade.php b/source/php/Module/Posts/views/index.blade.php index 176e07955..7e23f85be 100644 --- a/source/php/Module/Posts/views/index.blade.php +++ b/source/php/Module/Posts/views/index.blade.php @@ -1,7 +1,7 @@ @includeWhen(!$hideTitle && !empty($postTitle), 'partials.post-title') @includeWhen($preamble, 'partials.preamble') -
@if($posts) @foreach ($posts as $post) diff --git a/source/php/Module/Posts/views/partials/post/block.blade.php b/source/php/Module/Posts/views/partials/post/block.blade.php index 0a913c94f..b4631a1ff 100644 --- a/source/php/Module/Posts/views/partials/post/block.blade.php +++ b/source/php/Module/Posts/views/partials/post/block.blade.php @@ -6,14 +6,11 @@ 'secondaryMeta' => $post->readingTime, 'date' => $post->postDateFormatted, 'dateBadge' => $post->dateBadge, - 'filled' => true, 'image' => $post->image, - 'hasPlaceholder' => $post->hasPlaceholderImage, + //'hasPlaceholder' => $post->hasPlaceholderImage, 'classList' => ['t-posts-block', ' u-height--100'], 'context' => ['module.posts.block'], 'link' => $post->permalink, - 'postId' => $post->id, - 'postType' => $post->postType ?? '', 'icon' => $post->termIcon, 'attributeList' => array_merge($post->attributeList, []), ]) diff --git a/source/php/Module/Posts/views/partials/post/card.blade.php b/source/php/Module/Posts/views/partials/post/card.blade.php index 35c608d8c..1e9421a79 100644 --- a/source/php/Module/Posts/views/partials/post/card.blade.php +++ b/source/php/Module/Posts/views/partials/post/card.blade.php @@ -1,6 +1,5 @@ @card([ 'link' => $post->permalink, - 'imageFirst' => true, 'heading' => $post->postTitle, 'context' => ['module.posts.index'], 'content' => $post->excerptShort, @@ -10,11 +9,8 @@ 'dateBadge' => $post->dateBadge, 'classList' => ['u-height--100'], 'containerAware' => true, - 'hasAction' => true, 'hasPlaceholder' => $post->hasPlaceholderImage, 'image' => $post->image, - 'postId' => $post->id, - 'postType' => $post->postType, 'icon' => $post->termIcon, 'attributeList' => array_merge($post->attributeList, []), ]) diff --git a/source/php/Module/Posts/views/segment.blade.php b/source/php/Module/Posts/views/segment.blade.php index d13ad0ee1..fea6c362c 100644 --- a/source/php/Module/Posts/views/segment.blade.php +++ b/source/php/Module/Posts/views/segment.blade.php @@ -1,7 +1,8 @@ @includeWhen(!$hideTitle && !empty($postTitle), 'partials.post-title') @includeWhen($preamble, 'partials.preamble') + @if($posts) -
@foreach ($posts as $post)