Jump to content

Help with custom CSS code for Lightbox

Go to solution Solved by tuanphan,

Recommended Posts

Dear all,

I am looking for custom css code on which I could modify the Lightbox effect in Squarespace:

- in the 'Light version': being able to adjust the color (#d3d3d2) and transparency of the background (slightly seeing through the original site)

- Being able to modify the size of the lightbox, and center it on the page

- placing the 'close' cross on the right top of the image, instead of the right top page

- being able to zoom in the image (as in some web shops)

(website: www.pale-studio.com)

 

Many thanks for your precious help!

Elisabeth

Screenshot 2023-09-19 at 19.50.33.png

Screenshot 2023-09-19 at 19.50.38.png

Link to comment
  • Replies 5
  • Views 1.4k
  • Created
  • Last Reply

Top Posters In This Topic

On 9/21/2023 at 5:10 PM, Elisabethh said:

Dear Tuanphan, the page was inactive as I was building it.

Here is it, uploaded and finalised:

https://pale-studio.com/2301-wald-fabrics

 

Many thanks!

Thank you.

Can you enable Lightbox? Currently I can't click images to open lightbox

Email me if you have need any help (free, of course.). Answer within 24 hours. 
Or send to forum message

Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)

Link to comment

Just actived Lightbox on first the images as shown in attached screenshot.

URL: https://pale-studio.com/2301-wald-fabrics

 

Would like to modify the following:

- No title / text (at all) on Lightbox images 

- in the 'Light version': being able to adjust the color (#d3d3d2) and transparency of the background (slightly seeing through the original site)

- Being able to modify the size of the lightbox

- placing the 'close' cross on the right top of the image, instead of the right top page

- being able to zoom in the image (as in some web shops)

 

Many thanks!

Screenshot 2023-09-23 at 11.05.08.png

Link to comment
  • Solution

#1. To hide caption in lightbox, you can add this code to Page Settings > Advanced > Code Injection Header

<style>
  .yui3-lightbox2 .sqs-lightbox-meta {
    display: none !important;
}
</style>

#2. To adjust transparency

I see you used this code?

.sqs-lightbox-overlay.light {
    background: rgba(246,246,246,.98) !important;
    color: #3e3e3e;
}

#3. - placing the 'close' cross on the right top of the image, instead of the right top page

Right top - What do you mean? Or you mean right bottom?

#4. Zoom Image

This will require a custom plugin

Email me if you have need any help (free, of course.). Answer within 24 hours. 
Or send to forum message

Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.