Hi, thanks! This looks interesting. I’ll check it out.
I was also planning to look into this experimental feature of bud: Running multiple instances | bud.js.
By the way, in case anyone is interested: I have a working solution for selectable color schemes (and font stacks), inspired by a Sage user. CSS variables are defined differently based on the chosen theme (which can be chosen in a ACF option page). Those css variables are then used in both the tailwind palettes and in the theme.json palette. See below for a sketch. I you need transparency to work as well check out this video
_colors.scss
:
/* default theme */
:root {
/* https://tailcolor.com/palettes/60b502 */
--color-theme-1: #60b502;
--color-theme-1-50: #eff8e6;
--color-theme-1-100: #dff0cc;
--color-theme-1-200: #bfe19a;
--color-theme-1-300: #a0d367;
--color-theme-1-400: #80c435;
/* https://tailcolor.com/palettes/cb4d27 */
--color-theme-2: #cb4d27;
...
--color-text-link: var(--color-theme-2);
--color-text-menu-default-hover: var(--color-theme-2);
--color-bg-menu-colored: var(--color-theme-1);
/* Theme A */
.theme-a {
/* https://tailcolor.com/palettes/00889f */
--color-theme-1: #00889f;
--color-theme-1-50: #e6f3f5;
...
/* https://tailcolor.com/palettes/f58d00 */
--color-theme-2: #f58d00;
...
tailwind.config.cjs
…
theme: {
extend: {
textColor: {
inverted: 'var(--color-text-inverted)',
link: 'var(--color-text-link)',
...
t1: {
base: 'var(--color-theme-1)',
'50': 'var(--color-theme-1-50)',
...
},
t2: {
base: 'var(--color-theme-2)',
...
},
},
backgroundColor: {
menu: {
default: 'var(--color-bg-menu-default)',
colored: 'var(--color-bg-menu-colored)',
},
...
t1: {
base: 'var(--color-theme-1)',
...
},
borderColor {
...
}
theme.json
"settings": {
"color": {
"palette":[
...
{
"slug": "link",
"color": "var(--color-text-link)",
"name": "link"
},
{
"slug": "color-1",
"color": "var(--color-theme-1)",
"name": "theme color 1"
},
{
"slug": "color-1-50",
"color": "var(--color-theme-1-300)",
"name": "theme color 1 (300)"
},
...
{
"slug": "color-2",
"color": "var(--color-theme-2)",
"name": "theme color 2"
},