MCPcopy Create free account
hub / github.com/DavidHDev/react-bits / applyTransform

Function applyTransform

src/tailwind/Components/DomeGallery/DomeGallery.jsx:166–171  ·  view source on GitHub ↗
(xDeg, yDeg)

Source from the content-addressed store, hash-verified

164 const items = useMemo(() => buildItems(images, segments), [images, segments]);
165
166 const applyTransform = (xDeg, yDeg) => {
167 const el = sphereRef.current;
168 if (el) {
169 el.style.transform = `translateZ(calc(var(--radius) * -1)) rotateX(${xDeg}deg) rotateY(${yDeg}deg)`;
170 }
171 };
172
173 const lockedRadiusRef = useRef(null);
174

Callers 2

DomeGalleryFunction · 0.70
stepFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected