Can I add to my lightbox in&out slide transition?

I’m trying to add in&out slide transition to my lightbox, but when I write the code there’s an error says:

I can’t add a slide effect to the overlay background of the lightbox? only to the lightbox content itself?

here is my code:

let slideOptions = {
 "duration":   1500,
 "delay":      100,
 "direction" : "left"

export function close_mouseIn(event) {
     $w('#background').hide("slide", slideOptions) 

please advice :slight_smile:

I see here that I can only open lightbox, but how I can to add transition when it closed?

You can setup the lightbox-animations/transitions in the wix-ui (animations) directly on the lightbox itself.

A CODE-SOLUTION you will find here…