Universal color swapping?

I've used four analogous colors for my site but now the client wants a different scheme. Is there away to change every instance of a color on the site without changing each instance on each scene on each layout? I've use other programs that have a universal color swatch swap, that does just that. Cheers.

I haven't done this with a live project, soooooo… potentially dangerous!
You might want to backup your project before trying this technique
…and work with a copy of the project.
…as the following is just an experiment.

I created a Hype project with a red box. That color was #ff2600. So, let's say I didn't like that color red and I wanted to use the “Photics Blue” color… #4080bb.

The Hype Project should be closed at this point.

I opened the whole Hype project in Visual Studio Code, but it seems the main action was in the “data.plist” file. So, from there I just did a find and replace.

It worked. The box turned from red to blue.
The scene thumbnails were out-of-date, but Hype updated them quickly.


But in general, when I have a web project where I want to change the colors dynamically, I use CSS Variables. Here's some information…

It's not too difficult to add this kind of feature to a Hype project. It just involves a little bit of CSS and adding classes to the elements in Hype. But, for people that don't want to code, I suppose it would be better if Hype managed that.

I added “CSS Variables” as one of my recommendations for Hype 5.

1 Like

Thanks Phonics. After posting the question I thought of your solution as well--copy and replace the hex code in the finished css/html-- which is probably what I'll do. It would be really nice to experiment with colors and themes and to be able to do it on the fly in the hype document. I could even handle it on only a scene level (ie, control the colors for each scene dynamically.) but doing each layout gets really tedious. Let's hope it gets in the next hype version. cheers

1 Like

To chime in - I agree the only way to do it now is to manually edit the data.plist file with the find/replace unfortunately :-. But this would definitely be a good feature in the future.