pl-fe: fix colors

Signed-off-by: marcin mikołajczak <git@mkljczk.pl>
This commit is contained in:
marcin mikołajczak 2024-11-19 14:46:57 +01:00
parent dd3153b469
commit 0482d81c8b

View file

@ -52,7 +52,11 @@ const toTailwind = (config: {
const colors: PlFeColors = config.colors;
const legacyColors = fromLegacyColors(config);
return Object.fromEntries(Object.entries(legacyColors).map(([key, value]) => [key, typeof value === 'string' ? colors[key] || value : { ...value, ...colors[key] }]));
return {
...colors,
...Object.fromEntries(Object.entries(legacyColors).map(([key, value]) => [key, typeof value === 'string' ? colors[key] || value : { ...value, ...colors[key] }])),
};
};
export {