ped changes

This commit is contained in:
jason
2026-03-11 15:26:35 -05:00
parent 58b53c981e
commit 0a0a5d232c
2 changed files with 38 additions and 37 deletions

View File

@@ -46,13 +46,13 @@ const PedigreeTree = ({ dogId, pedigreeData, coi }) => {
: (isMale ? 'rgba(59,130,246,0.3)' : 'rgba(236,72,153,0.3)')
const ringColor = isRoot ? rootAccent : nodeColor
const r = isRoot ? 34 : 28
const r = isRoot ? 46 : 38
return (
<g>
{/* Glow halo */}
<circle
r={r + 10}
r={r + 12}
fill={glowColor}
style={{ filter: 'blur(6px)' }}
/>
@@ -95,10 +95,10 @@ const PedigreeTree = ({ dogId, pedigreeData, coi }) => {
{/* Gender / crown icon */}
<text
fill={isRoot ? '#fff' : '#fff'}
fontSize={isRoot ? 22 : 18}
fill="#fff"
fontSize={isRoot ? 26 : 22}
textAnchor="middle"
dy="7"
dy="8"
style={{ pointerEvents: 'none', userSelect: 'none' }}
>
{isRoot ? '👑' : (isMale ? '♂' : '♀')}
@@ -106,14 +106,14 @@ const PedigreeTree = ({ dogId, pedigreeData, coi }) => {
{/* Name label */}
<text
fill="var(--text-primary, #f5f0e8)"
fontSize={isRoot ? 15 : 13}
fill="var(--text-primary, #ffffff)"
fontSize={isRoot ? 18 : 15}
fontWeight={isRoot ? '700' : '600'}
fontFamily="Inter, sans-serif"
textAnchor="middle"
x="0"
y={r + 18}
style={{ pointerEvents: 'none' }}
y={r + 24}
style={{ pointerEvents: 'none', textShadow: '0 2px 4px rgba(0,0,0,0.8)' }}
>
{nodeDatum.name}
</text>
@@ -121,13 +121,13 @@ const PedigreeTree = ({ dogId, pedigreeData, coi }) => {
{/* Breed label (subtle) */}
{breed && (
<text
fill="var(--text-muted, #8c8472)"
fontSize="10"
fill="var(--text-muted, #d1d5db)"
fontSize="12"
fontFamily="Inter, sans-serif"
textAnchor="middle"
x="0"
y={r + 31}
style={{ pointerEvents: 'none' }}
y={r + 42}
style={{ pointerEvents: 'none', textShadow: '0 1px 3px rgba(0,0,0,0.8)' }}
>
{breed}
</text>
@@ -136,13 +136,13 @@ const PedigreeTree = ({ dogId, pedigreeData, coi }) => {
{/* Registration number */}
{nodeDatum.attributes?.registration && (
<text
fill="var(--text-muted, #8c8472)"
fontSize="10"
fill="var(--text-muted, #d1d5db)"
fontSize="12"
fontFamily="Inter, sans-serif"
textAnchor="middle"
x="0"
y={r + (breed ? 44 : 31)}
style={{ pointerEvents: 'none' }}
y={r + (breed ? 58 : 42)}
style={{ pointerEvents: 'none', textShadow: '0 1px 3px rgba(0,0,0,0.8)' }}
>
{nodeDatum.attributes.registration}
</text>
@@ -151,13 +151,13 @@ const PedigreeTree = ({ dogId, pedigreeData, coi }) => {
{/* Birth year */}
{nodeDatum.attributes?.birth_year && (
<text
fill="var(--text-muted, #8c8472)"
fontSize="10"
fill="var(--text-muted, #d1d5db)"
fontSize="12"
fontFamily="Inter, sans-serif"
textAnchor="middle"
x="0"
y={r + (breed ? 57 : (nodeDatum.attributes?.registration ? 44 : 31))}
style={{ pointerEvents: 'none' }}
y={r + (breed ? 74 : (nodeDatum.attributes?.registration ? 58 : 42))}
style={{ pointerEvents: 'none', textShadow: '0 1px 3px rgba(0,0,0,0.8)' }}
>
({nodeDatum.attributes.birth_year})
</text>
@@ -232,8 +232,8 @@ const PedigreeTree = ({ dogId, pedigreeData, coi }) => {
}}
orientation="horizontal"
pathFunc="step"
separation={{ siblings: 1.6, nonSiblings: 2.2 }}
nodeSize={{ x: 220, y: 160 }}
separation={{ siblings: 1.8, nonSiblings: 2.4 }}
nodeSize={{ x: 280, y: 200 }}
renderCustomNodeElement={renderCustomNode}
enableLegacyTransitions
transitionDuration={300}