WPIntell

Source evidence

How to reduce vertical space between posts

Latest Post Shortcode · support · 2024-09-02T19:15:00+00:00

mixedsentiment
mediumseverity
0.84relevance
4replies
Evidence linked to opportunitycommercial context

Proof Health

Open evidence

Commercial opportunities need traceable source links before they are treated as build-worthy.

3 / 31 rows with source links

9.7% of this page's analysis has direct source links.

0 build-decision rows missing links

0 rows here require auditable proof before promotion.

28 rows with no attached evidence

0 rows have source counts but still need direct links.

Conversation

support
lklawless resolved
I’ve tried the shortcode both within the post text and in the footer, and there is just way too much vertical space between the posts, and even between the title and the first post. I’ve gone over and over the settings but can’t figure out how to reduce this gap. I’ve tried the default height and, currently, 1ps height, but it’s the same thing. Help? [latest-selected-content ver="2" limit="4" display="title,excerpt" titletag="h4" url="yes" elements="26" default_height="1px" tablet_height="1px" mobile_height="1px" type="post" status="publish" orderby="dateD"] View post on imgur.com The page I need help with: [ log in to see the link] Hi, You can test with changing a bit the padding and gap overrides: [latest-selected-content ver="2" limit="4" display="title,excerpt" titletag="h4" url="yes" elements="26" default_height="auto" default_padding="0.25rem" default_gap="0.25rem" tablet_height="auto" tablet_padding="0.25rem" tablet_gap="0.25rem" mobile_height="auto" mobile_padding="0.25rem" mobile_gap="0.25rem" css="content-center" type="post" status="publish" orderby="dateD"] Then you could also check for the section id and do something like this in your CSS (your section id is probably going to be something else): #lps-2d288f37f450b121d4bcbd0f6e85e10e {grid-auto-rows: auto;} If this is not enough, we could take a look at the styles for the h4 in your theme, to see if the global styles are applying some top margin to all, and maybe override it for the cards. Let me know how it goes. Regards, Iulia Hi Iulia, Thank you for responding. The new code you suggested reduced the space only by a tiny amount. The section id change custom_html-7{grid-auto-rows: auto;} didn’t do anything at all. I’m not great with css, but this is what I found: in custom css, I have h1, h2, h3, h4, h5 { line-height: 1em !important; } And in style.css, I have h1, h2, h3, h4, h5, h6 { color: #3c312e; font-family: Raleway, Arial, Helvetica, sans-serif; padding-bottom: 5px; line-height: 1em; } Current shortcode: [latest-selected-content ver="2" limit="4" display="title,excerpt" titletag="h4" url="yes" linktext="¡Vamos!" elements="26" default_height="auto" default_padding="0.25rem" default_gap="0.25rem" tablet_height="auto" tablet_padding="0.25rem" tablet_gap="0.25rem" mobile_height="auto" mobile_padding="0.25rem" mobile_gap="0.25rem" css="two-columns as-column content-center" type="post" status="publish" orderby="dateD"] Hi, Looking at the markup I saw that the margin is added to the hentry, maybe you could try this instead: #custom_html-7 .latest-post-selection.two-columns { grid-auto-rows: auto !important; } #custom_html-7 .hentry { margin-top: 0 !important; } Let’s see if this helps. Regards, Iulia That did it. Thank you so much!

Comments

4 shown
Iulia Cazan 2024-09-03T06:19:00+00:00

Hi, You can test with changing a bit the padding and gap overrides: [latest-selected-content ver="2" limit="4" display="title,excerpt" titletag="h4" url="yes" elements="26" default_height="auto" default_padding="0.25rem" default_gap="0.25rem" tablet_height="auto" tablet_padding="0.25rem" tablet_gap="0.25rem" mobile_height="auto" mobile_padding="0.25rem" mobile_gap="0.25rem" css="content-center" type="post" status="publish" orderby="dateD"] Then you could also check for the section id and do something like this in your CSS (your section id is probably going to be something else): #lps-2d288f37f450b121d4bcbd0f6e85e10e {grid-auto-rows: auto;} If this is not enough, we could take a look at the styles for the h4 in your theme, to see if the global styles are applying some top margin to all, and maybe override it for the cards. Let me know how it goes. Regards, Iulia

lklawless 2024-09-03T12:31:00+00:00

Hi Iulia, Thank you for responding. The new code you suggested reduced the space only by a tiny amount. The section id change custom_html-7{grid-auto-rows: auto;} didn’t do anything at all. I’m not great with css, but this is what I found: in custom css, I have h1, h2, h3, h4, h5 { line-height: 1em !important; } And in style.css, I have h1, h2, h3, h4, h5, h6 { color: #3c312e; font-family: Raleway, Arial, Helvetica, sans-serif; padding-bottom: 5px; line-height: 1em; } Current shortcode: [latest-selected-content ver="2" limit="4" display="title,excerpt" titletag="h4" url="yes" linktext="¡Vamos!" elements="26" default_height="auto" default_padding="0.25rem" default_gap="0.25rem" tablet_height="auto" tablet_padding="0.25rem" tablet_gap="0.25rem" mobile_height="auto" mobile_padding="0.25rem" mobile_gap="0.25rem" css="two-columns as-column content-center" type="post" status="publish" orderby="dateD"]

Iulia Cazan 2024-09-03T14:23:00+00:00

Hi, Looking at the markup I saw that the margin is added to the hentry, maybe you could try this instead: #custom_html-7 .latest-post-selection.two-columns { grid-auto-rows: auto !important; } #custom_html-7 .hentry { margin-top: 0 !important; } Let’s see if this helps. Regards, Iulia

lklawless 2024-09-03T16:00:00+00:00

That did it. Thank you so much!