import React from 'react'; import { Svg, G, Path } from '@react-pdf/renderer'; const hexToRgb = (hex: string) => { const bigint = parseInt(hex.slice(1), 16); return [(bigint >> 16) & 255, (bigint >> 8) & 255, bigint & 255]; }; const getSolidHex = (fgHex: string, alpha: number, bgHex: string) => { if (alpha >= 1) return fgHex; const [fr, fg, fb] = hexToRgb(fgHex); const [br, bg, bb] = hexToRgb(bgHex); const r = Math.round(fr * alpha + br * (1 - alpha)); const g = Math.round(fg * alpha + bg * (1 - alpha)); const b = Math.round(fb * alpha + bb * (1 - alpha)); return '#' + [r, g, b].map((x) => x.toString(16).padStart(2, '0')).join(''); }; const getRGBA = (hex: string, alpha: number) => { const [r, g, b] = hexToRgb(hex); return `rgba(${r}, ${g}, ${b}, ${alpha})`; }; export const TruckBlueprint = ({ style, opacity = 1, backgroundColor = '#ffffff', }: { style?: any; opacity?: number; backgroundColor?: string; }) => { console.log( 'TruckBlueprint rendering with opacity:', opacity, 'and backgroundColor:', backgroundColor, ); return ( ); };