Linking specific lightboxes in dynamic repeater

Question:
How can I attach specific lightboxes to CMS list items?

Product:
Wix Studio Editor

What are you trying to achieve:
I’m trying to figure out how to cause a button in a container in a “meet our team” repeater to open a lightbox corresponding to the CMS item. The Lightboxes for the team members are made separately and have different formatting.
If this is not possible, would it be possible to remove the dynamic formatting from the repeater while leaving the content that is currently in it so I don’t have to rebuild it?

Everything is possible!

  1. You are using a repeater?
  2. You have a connected DATASET ? → (dynamic) ?
  3. Or do you populate your repeater by code?

The are the first important questions, you should ask yourself.

4) If using a dataset, your starting CODE-SEQUENCE should look like…

$w.onReady(()=>{
    $w('#myDatasetIdHere').onReady(()={

    });
});

5) followed by the REPEATER CODE-SEQUENCE…(depending on how is connected your REPEATER in your SETUP (DATASET od CODE)…

$w.onReady(()=>{
    $w('#myDatasetIdHere').onReady(()={
        $w('#myRepeaterIdHere').onItemReady($i, iData, index()=>{
            console.log('Data: ' iData);
        });
    });
});

6) Adding the REPEATER-BUTTON functionality…

$w.onReady(()=>{
    $w('#myDatasetIdHere').onReady(()={
        $w('#myRepeaterIdHere').onItemReady($i, iData, index()=>{
            console.log('Data: ' iData);

            $i('#myButtonInsideRepeaterIDHere').onClick((e)=>{
                 console.log(e.target.id + '-clicked');
            });
        });
    });
});

6) Now try to continue stept by step code-construction for your needs…