Files
blitzkit/packages/website/src/components/HelpingSpotLight.tsx
T

20 lines
452 B
TypeScript
Raw Normal View History

2025-09-27 16:07:45 -05:00
import { memo, type ComponentProps } from "react";
2025-08-28 17:59:31 -05:00
2025-09-27 16:07:45 -05:00
interface Props extends ComponentProps<"spotLight"> {
2025-08-28 17:59:31 -05:00
debug?: boolean;
}
2025-08-29 13:21:41 -05:00
export const HelpingSpotLight = memo<Props>(({ debug, ...props }) => {
2025-08-28 17:59:31 -05:00
return (
<>
{debug && (
<mesh position={props.position}>
<icosahedronGeometry args={[0.1, 2]} />
<meshBasicMaterial color={props.color} />
</mesh>
)}
2025-08-29 22:51:24 -05:00
<spotLight {...props} />
2025-08-28 17:59:31 -05:00
</>
);
2025-08-29 13:21:41 -05:00
});