feat: phase 2 visual improvements for CareerConstellation
- Links: domain-colored with strength-weighted width/opacity, improved bezier curves - Skill nodes: domain-colored stroke, size encoding by connected role count, glow filter on highlight - Role nodes: gradient fill (orgColor 0.08→0.18), enhanced highlight with fill-opacity and stroke-width - Entry animation: staggered reveal (guides→roles→skills→links with stroke-dashoffset), skipped under prefers-reduced-motion - Legend: domain node counts displayed
This commit is contained in:
@@ -3,13 +3,14 @@ import { supportsCoarsePointer } from './constants'
|
||||
|
||||
interface ConstellationLegendProps {
|
||||
isTouch: boolean
|
||||
domainCounts?: Record<string, number>
|
||||
}
|
||||
|
||||
export const ConstellationLegend: React.FC<ConstellationLegendProps> = ({ isTouch }) => {
|
||||
export const ConstellationLegend: React.FC<ConstellationLegendProps> = ({ isTouch, domainCounts }) => {
|
||||
const items = [
|
||||
{ label: 'Technical', color: 'var(--accent)' },
|
||||
{ label: 'Clinical', color: 'var(--success)' },
|
||||
{ label: 'Leadership', color: 'var(--amber)' },
|
||||
{ label: 'Technical', domain: 'technical', color: 'var(--accent)' },
|
||||
{ label: 'Clinical', domain: 'clinical', color: 'var(--success)' },
|
||||
{ label: 'Leadership', domain: 'leadership', color: 'var(--amber)' },
|
||||
]
|
||||
|
||||
return (
|
||||
@@ -42,7 +43,7 @@ export const ConstellationLegend: React.FC<ConstellationLegendProps> = ({ isTouc
|
||||
flexShrink: 0,
|
||||
}}
|
||||
/>
|
||||
{item.label}
|
||||
{item.label}{domainCounts?.[item.domain] != null ? ` (${domainCounts[item.domain]})` : ''}
|
||||
</span>
|
||||
</React.Fragment>
|
||||
))}
|
||||
|
||||
Reference in New Issue
Block a user