I want a repeater colour option that changes my image gallery using a database?

I am designing a website for a Store who sells kitchens. They want a online “brochure”. I am trying to create a dynamic page via a database. Each kitchen they sell has multiple variations in colour. What i want to do is have a button, that when clicked it changes the viewable image gallery to those colour images.

I have played around with referencing and filtering but i think this needs some code to work, however ive just started coding and need some help where i would start with this.

So far i have set up a database for the kitchen and details and a seperate database for each colour, referecing that kitchen. I have set up a dynamic page and messed around with repeaters . I can get the colour images to appear but i cannot set up the function of clicking a colour and having the coloured kitchen appear in the gallery.

Hope thats makes sense, any help is appreciated!