diff --git a/app/app/components/chord-diagram/guitar-fretboard.tsx b/app/app/components/chord-diagram/guitar-fretboard.tsx index bb9b001..d4ff27d 100644 --- a/app/app/components/chord-diagram/guitar-fretboard.tsx +++ b/app/app/components/chord-diagram/guitar-fretboard.tsx @@ -1,7 +1,13 @@ import type { GuitarVoicing } from '~/lib/chord-voicing'; -const FRETS_SHOWN = 4; const STRING_COUNT = 6; +const FRET_COUNT = 4; +const STRING_SPACING = 13; // px between adjacent string lines +const FRET_HEIGHT = 18; // px per fret +const DOT_R = 5; // finger dot radius + +const GRID_W = STRING_SPACING * (STRING_COUNT - 1); // 65px +const GRID_H = FRET_HEIGHT * FRET_COUNT; // 72px interface Props { voicing: GuitarVoicing | null; @@ -10,93 +16,139 @@ interface Props { export function GuitarFretboard({ voicing }: Props) { if (!voicing) { return ( -