Fixes audio visualizer color issues (#19)

This commit is contained in:
mattherzog
2024-01-21 15:05:35 -08:00
committed by GitHub
parent 0acc27e406
commit 2ec251c93c
2 changed files with 3 additions and 2 deletions

View File

@@ -72,11 +72,11 @@ export const AgentMultibandAudioVisualizer = ({
{summedFrequencies.map((frequency, index) => {
const isCenter = index === Math.floor(summedFrequencies.length / 2);
let color = accentColor;
let color = `${accentColor}-${accentShade}`;
let shadow = `shadow-lg-${accentColor}`;
let transform;
if (state === "listening") {
if (state === "listening" || state === "idle") {
color = isCenter ? `${accentColor}-${accentShade}` : "gray-950";
shadow = !isCenter ? "" : shadow;
transform = !isCenter ? "scale(1.0)" : "scale(1.2)";