# M scroll progress 1

> Fixed reading bar — 1px bar pinned to viewport top tracks window scroll

A shadcn/ui block from the [@cnippet](https://ui.cnippet.dev/) registry, listed on [shadcn.exchange](https://shadcn.exchange/r/cnippet/m-scroll-progress-1).

- Page, with a live preview: https://shadcn.exchange/r/cnippet/m-scroll-progress-1
- Screenshot: https://abzjhwgwpdpz7ua5.public.blob.vercel-storage.com/shots/cnippet/m-scroll-progress-1-light-98ba0394cb854fef.png
- Registry item: https://ui.cnippet.dev/r/m-scroll-progress-1.json
- Categories: scroll progress
- Listed: 2026-10-13, source last changed 2026-10-13

## Install

```bash
npx shadcn@latest add https://ui.cnippet.dev/r/m-scroll-progress-1.json
```

Run it in a project that has shadcn/ui set up. It adds the files below and installs what they depend on.

## Dependencies

- Registry items: `@cnippet/scroll-progress`

## Files

### `registry/default/motion-variants/m-scroll-progress-1.tsx`

```tsx
"use client";

import { ScrollProgress } from "@/registry/default/motion/scroll-progress";

export default function ScrollProgressFixed() {
  return (
    <div className="relative flex min-h-50 flex-col items-center justify-start overflow-y-auto px-6">
      <div className="sticky top-0 z-10 w-full">
        <ScrollProgress className="fixed top-0 right-0 left-0 h-1 bg-primary" />
      </div>
      <div className="w-full max-w-lg space-y-4 py-6">
        <h2 className="font-bold text-foreground text-xl">
          Scroll to see progress
        </h2>
        {Array.from({ length: 6 }).map((_, i) => (
          <p className="text-muted-foreground text-sm leading-relaxed" key={i}>
            Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed do
            eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim
            ad minim veniam, quis nostrud exercitation ullamco laboris.
          </p>
        ))}
      </div>
    </div>
  );
}
```
