AE Controller for changing layer into specific colours I'm trying to create an Essential Graphic that allows the user to change a layer's colour into 4 specific ones:
Teal: 7, 250, 198
Pink: 252, 12, 119
Black: 0, 0, 0
White: 255, 255, 255

Colour Control isn't an option as it gives too much freedom.
Checkbox Control isn't either as it is not a 2 colours boolean/switch.

A Slider Control I think would be a good option but I need something similar to the clamp expression to keep the slider in control, something that would make my slider move in ones or specific steps.
Maybe I'm completely off track, I'm open to better solutions!
Use a dropdown. Select Dropdown Expression Control from Effects&gt;Expression Controls and hit edit to input the colour names.

Then use a switch to deal with the four possible choices.
let colourChoice = Math.round(thisComp.layer(&quot;White Solid 1&quot;).effect(&quot;Dropdown Menu Control&quot;)(&quot;Menu&quot;));
switch (colourChoice){
    case 1 : [7, 250, 198, 255]/255.0;
        break;
    case 2 : [252, 12, 119, 255]/255.0;
        break;
    case 3 : [0, 0, 0, 0];
        break;
    default:  [1, 1, 1, 1];

}
N.B.:

Math.round on the firstline is to convert the numeric result returned from the dropdown to an integer, I'm not sure what kind of numerical value is returned from a dropdown, but just using let colourChoice = thisComp.layer(&quot;White Solid 1&quot;).effect(&quot;Dropdown Menu Control&quot;)(&quot;Menu&quot;) doesn't work.

Colours in expressions are four-dimensional RGBA arrays, because even if they don't use alpha they need a value for alpha.

And finally the / 255 after the array is to convert the 0-255 RGBA values into 0-1.0 floating point values for colour. You could do the maths beforehand, but it's more legible like this.