Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Whitespace between content page's title and accordion content when body field isn't used #866

Closed
Detzner opened this issue Nov 2, 2022 · 6 comments
Labels
Milestone

Comments

@Detzner
Copy link
Contributor

Detzner commented Nov 2, 2022

Almost all pages used an accordion paragraph for the content. There was 1.25 - 1.5 inches of space between the page title and the heading for the accordion (see attached). It looks like there's a div inserted above the paragraph where content begins, using this code:

<style type="text/css">

/--><!]]>/
</style>

To fix this I added CSS to have negative margin under the page title, and then gave the paragraph block under the title a transparent background so that it wouldn't obscure the title. But I don't know why that div.field--name-body is there creating an empty 3/4" of space.

Example of the issue is at https://drupal-sandbox.webtheme.illinois.edu/accordion-without-sidebar-or-body-content

image

@mwllr
Copy link
Contributor

mwllr commented Nov 4, 2022

Same as issue #815 @wrg20

@mwllr mwllr added this to the V3.0 milestone Nov 15, 2022
@wrg20
Copy link
Contributor

wrg20 commented Dec 13, 2022

@Detzner - do you have a page where this is happening that I can reference? I think I know what you are talking about but I just wanted to make sure. I would like for you to be able to remove the negative margin. I think the problem is probably when there is no body content entered but the div is still being rendered (based on your description).

@Detzner
Copy link
Contributor Author

Detzner commented Dec 14, 2022 via email

@wrg20
Copy link
Contributor

wrg20 commented Dec 14, 2022

Thanks @Detzner.

@mwllr - I can't remember if we intended to indent the title or have it inline with the block I.
image

As for the spacing issue. It appears that we are not doing a check on the body field to see if there is content or not. I will have to do a check on that field and that should resolve the spacing issue. The screenshot below shows Dick's website with no content in the body field for the page.
image

@trubach trubach modified the milestones: V3.0, v3.1 Mar 1, 2023
@trubach
Copy link
Contributor

trubach commented Mar 1, 2023

I think this issue is not resolved and not related to #815. I created a page with the issue at:

https://drupal-sandbox.webtheme.illinois.edu/accordion-without-sidebar-or-body-content

and it still has a lot of padding between the title and first text. I didn't see the <style> tag that Dick sees on his site, but it still looks like we should try and shrink the padding between the page heading and the paragraph heading when the body field isn't used.

@trubach trubach added the cleanup label Mar 1, 2023
@trubach trubach changed the title extra white space under the page titles on the content pages on isg.illinois.edu Whitespace between content page's title and accordion content when body field isn't used Mar 1, 2023
@trubach
Copy link
Contributor

trubach commented Mar 19, 2024

Closing - now tracked in issue #988

@trubach trubach closed this as completed Mar 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants