Solved

How use Visibility Hidden CSS to hide H2 title of a Shopify Section

Re4lityShaper
Tourist
25 0 2

Hello,

 

I would like to use "visibility hidden" in order to hide the H2 of a shopify section.

Thanks.

Accepted Solution (1)

JennerDev
Excursionist
16 4 2

This is an accepted solution.

h2 {
  visibility: hidden !important;
}

Please note, that the element will be hidden, but the location, padding, and margin will remain there! - you will see a blank gap on the page

If you would like to hide the element completely then use:

h2 {
  display: none !important;
}

View solution in original post

Replies 3 (3)

JennerDev
Excursionist
16 4 2

This is an accepted solution.

h2 {
  visibility: hidden !important;
}

Please note, that the element will be hidden, but the location, padding, and margin will remain there! - you will see a blank gap on the page

If you would like to hide the element completely then use:

h2 {
  display: none !important;
}
Re4lityShaper
Tourist
25 0 2
Ok but I thought "display: none;" was keeping the rendering of the H2 bc
the blocks moved, not with "visibility: hidden;".

Anyway, thanks.
marthedesigner
Shopify Partner
10 0 0

Hii, Jenner. How could I apply this to collection titles in a collection compliation page?

I tried, but didn't work:

collection.title {
visibility: hidden !important;
}

Thanks!

☁️ Email Marketing, SEO and Ecommerce + Klaviyo and Shopify Certified Partner 落