Help with what I think is JavaScript
July 8, 2024 11:25 AM   Subscribe

I am trying to incorporate this widget into my Ghost CMS. It's working, but I'd like to tweak it.

As you can see on the page, it says that I can change the background color. I'd like to make it black instead of white but don't know where to put it and don't know the syntax. I assume I need to put background="#000" somewhere, but where? I've tried what I consider the obvious places, and though it it doesn't give me an error, it doesn't change the BG color.

posted by dobbs to Computers & Internet (3 answers total)
Best answer: When you do the script to call mediumZoom, you need to add a second parameter with your options:

mediumZoom('.kg-image-card img,.kg-gallery-card img', { background: '#000000' })

Something like that I assume. That's just based on the documentation in your link. I didn't try it.
posted by cmm at 11:40 AM on July 8 [1 favorite]

Or you can configure the whole site to have the same background color.
posted by kschang at 11:43 AM on July 8

Response by poster: Thanks, cmm. That worked.

kschang, the rest of the site already has a black background.
posted by dobbs at 12:57 PM on July 8

« Older Help me see behind me better!   |   Steve Jobs quote about not being irreplaceable Newer »

You are not logged in, either login or create an account to post comments