The HorizontalScroll component is a high-impact layout technique often used in Awwwards-winning websites to showcase portfolios, image galleries, or features. It leverages Framer Motion's useScroll and useTransform hooks to hijack the vertical scroll and map it to a horizontal X-axis translation.
Live Preview
Scroll Down
End of Section
Installation
npx kinetic-ui-cli@latest add horizontal-scrollUsage Guide
1. Import the Component
Import the component into your React or Next.js page:
import { HorizontalScroll } from "@/components/creative/horizontal-scroll";
2. Implementation Example
Render the component and customize its behavior by passing props:
import { HorizontalScroll } from "@/components/creative/horizontal-scroll";
export default function Example() {
return (
<div className="w-full flex items-center justify-center p-8">
<HorizontalScroll
containerRef{/* value */}
>
<div>Content goes here</div>
</HorizontalScroll>
</div>
);
}