From 64cea82599ae3b4ac971058f0e67ae5aacfd10ba Mon Sep 17 00:00:00 2001 From: cahdeemer Date: Thu, 27 Jun 2024 11:15:22 -0400 Subject: [PATCH 1/6] add some defaults to latest posts block --- block-filters/latest-posts/index.tsx | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/block-filters/latest-posts/index.tsx b/block-filters/latest-posts/index.tsx index 5f7e00ab..7de54511 100644 --- a/block-filters/latest-posts/index.tsx +++ b/block-filters/latest-posts/index.tsx @@ -24,6 +24,12 @@ function modifyLatestPostsSupports(settings, name) { excerptLength: { default: 20, }, + featuredImageAlign: { + default: 'left', + }, + featuredImageSizeSlug: { + default: 'medium', + }, }), supports: Object.assign(settings.supports, { align: [], From f8021b3122bdd6ef77236aeae6203a3e0e01621e Mon Sep 17 00:00:00 2001 From: cahdeemer Date: Thu, 27 Jun 2024 16:00:21 -0400 Subject: [PATCH 2/6] add more defaults to latest posts block --- block-filters/latest-posts/index.tsx | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/block-filters/latest-posts/index.tsx b/block-filters/latest-posts/index.tsx index 7de54511..efa517c5 100644 --- a/block-filters/latest-posts/index.tsx +++ b/block-filters/latest-posts/index.tsx @@ -24,12 +24,18 @@ function modifyLatestPostsSupports(settings, name) { excerptLength: { default: 20, }, + displayFeaturedImage: { + default: true, + }, featuredImageAlign: { default: 'left', }, featuredImageSizeSlug: { default: 'medium', }, + addLinkToFeaturedImage: { + default: true, + }, }), supports: Object.assign(settings.supports, { align: [], From d6c5c864c4bfab3a9e17e0b1fc98ac64eadfe231 Mon Sep 17 00:00:00 2001 From: cahdeemer Date: Thu, 27 Jun 2024 16:00:38 -0400 Subject: [PATCH 3/6] wip --- scss/core-blocks/latest-posts.scss | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/scss/core-blocks/latest-posts.scss b/scss/core-blocks/latest-posts.scss index 3d635628..1a4c41c8 100644 --- a/scss/core-blocks/latest-posts.scss +++ b/scss/core-blocks/latest-posts.scss @@ -21,12 +21,14 @@ width: 100%; > * { - margin: 16px; + margin-bottom: 16px; + margin-top: 16px; } } img { max-width: 250px; + width: 250px; } .wp-block-latest-posts__post-title { @@ -51,7 +53,7 @@ width: 100%; img { - max-width: 90%; + max-width: 100%; width: 100%; } } @@ -90,8 +92,8 @@ } img { - max-width: 100%; - width: 100%; + max-width: 300px; + width: 300px; } } } From 89d32c48a30013390750fa8068784919a4445922 Mon Sep 17 00:00:00 2001 From: cahdeemer Date: Thu, 27 Jun 2024 17:35:58 -0400 Subject: [PATCH 4/6] remove default attributes on latest post block because they do not actually do anything --- block-filters/latest-posts/index.tsx | 17 ----------------- 1 file changed, 17 deletions(-) diff --git a/block-filters/latest-posts/index.tsx b/block-filters/latest-posts/index.tsx index efa517c5..8345029e 100644 --- a/block-filters/latest-posts/index.tsx +++ b/block-filters/latest-posts/index.tsx @@ -20,23 +20,6 @@ function modifyLatestPostsSupports(settings, name) { ) { return { ...settings, - attributes: Object.assign(settings.attributes, { - excerptLength: { - default: 20, - }, - displayFeaturedImage: { - default: true, - }, - featuredImageAlign: { - default: 'left', - }, - featuredImageSizeSlug: { - default: 'medium', - }, - addLinkToFeaturedImage: { - default: true, - }, - }), supports: Object.assign(settings.supports, { align: [], anchor: false, From dd6c10e0fb550fc9546ed32b53bf2d75eb66e857 Mon Sep 17 00:00:00 2001 From: cahdeemer Date: Thu, 27 Jun 2024 17:36:20 -0400 Subject: [PATCH 5/6] sort out media queries --- scss/core-blocks/latest-posts.scss | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) diff --git a/scss/core-blocks/latest-posts.scss b/scss/core-blocks/latest-posts.scss index 1a4c41c8..aba8c5f2 100644 --- a/scss/core-blocks/latest-posts.scss +++ b/scss/core-blocks/latest-posts.scss @@ -89,11 +89,24 @@ li { display: block; width: 100%; + + div { + display: block; + float: none; + } } - img { - max-width: 300px; - width: 300px; + .wp-block-latest-posts__featured-image.alignleft, + .wp-block-latest-posts__featured-image.alignright { + display: block; + float: none; + width: 100%; + + img { + display: block; + max-width: 100%; + width: 100%; + } } } } From 10fc4d4e02eb92d0d009f207ebcdd2c347d9e56f Mon Sep 17 00:00:00 2001 From: cahdeemer Date: Thu, 27 Jun 2024 17:49:42 -0400 Subject: [PATCH 6/6] bump version --- README.md | 2 +- plugin.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 193bc43f..26d87f41 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,7 @@ Contributors: alleyinteractive Tags: alleyinteractive, wp-newsletter-builder -Stable tag: 0.3.33 +Stable tag: 0.3.34 Requires at least: 6.2 diff --git a/plugin.php b/plugin.php index 36732920..b1deaf41 100644 --- a/plugin.php +++ b/plugin.php @@ -3,7 +3,7 @@ * Plugin Name: Newsletter Builder * Plugin URI: https://github.com/alleyinteractive/wp-newsletter-builder * Description: Interface to manage email newsletters - * Version: 0.3.33 + * Version: 0.3.34 * Author: Alley Interactive * Author URI: https://github.com/alleyinteractive/wp-newsletter-builder * Requires at least: 6.2