# Feature Timeline

> A vertical timeline that walks through product features in sequence. Useful for showing a setup flow or how capabilities build on each other.

A shadcn/ui block from the [@shadcn-ui-blocks](https://www.shadcn-ui-blocks.com) registry, listed on [shadcn.exchange](https://shadcn.exchange/r/shadcn-ui-blocks/ecommerce-product-features-feature-timeline).

- Page, with a live preview: https://shadcn.exchange/r/shadcn-ui-blocks/ecommerce-product-features-feature-timeline
- Screenshot: https://abzjhwgwpdpz7ua5.public.blob.vercel-storage.com/shots/shadcn-ui-blocks/ecommerce-product-features-feature-timeline-light-1cc6e227853a92e5.png
- Registry item: https://www.shadcn-ui-blocks.com/r/ecommerce-product-features-feature-timeline.json
- Listed: 2026-10-13, source last changed 2026-10-13

## Install

```bash
npx shadcn@latest add https://www.shadcn-ui-blocks.com/r/ecommerce-product-features-feature-timeline.json
```

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

## Dependencies

- npm packages: `class-variance-authority`, `lucide-react`, `radix-ui`

## Files

### `components/blocks/ecommerce/product-features/feature-timeline.tsx`

```tsx
import {
  ArrowRight,
  Heart,
  Timer,
  Smartphone,
  Zap,
  Droplet,
  Activity,
} from 'lucide-react';
import { Badge } from '@/components/ui/badge';
import { Button } from '@/components/ui/button';
import { cn } from '@/lib/utils';

export default function FeatureTimeline() {
  const features = [
    {
      id: 1,
      title: 'Advanced Health Monitoring',
      description:
        'Continuous heart rate tracking with abnormality alerts, blood oxygen saturation measurement, and stress level analysis with guided breathing exercises.',
      icon: <Heart className="h-5 w-5" />,
      image:
        'https://images.unsplash.com/photo-1557438159-51eec7a6c9e8?q=80&w=2070&auto=format&fit=crop',
      color: 'bg-rose-50 text-rose-600 dark:bg-rose-950/20 dark:text-rose-400',
      position: 'left',
      stats: [
        { value: '24/7', label: 'Monitoring' },
        { value: '±1%', label: 'Accuracy' },
        { value: '5min', label: 'Intervals' },
      ],
    },
    {
      id: 2,
      title: '7-Day Battery Life',
      description:
        'Intelligent power management with smart display and processor optimization delivers a full week of use on a single charge, even with always-on display and activity tracking.',
      icon: <Zap className="h-5 w-5" />,
      image:
        'https://images.unsplash.com/photo-1579586337278-3befd40fd17a?q=80&w=2072&auto=format&fit=crop',
      color:
        'bg-amber-50 text-amber-600 dark:bg-amber-950/20 dark:text-amber-400',
      position: 'right',
      stats: [
        { value: '7', label: 'Days' },
        { value: '45min', label: 'Full Charge' },
        { value: '2hrs', label: 'Quick Charge' },
      ],
    },
    {
      id: 3,
      title: 'Workout Intelligence',
      description:
        'Automatically detects 12 different exercise types and provides detailed metrics including cadence, pace, heart rate zones, and calories burned with personalized insights.',
      icon: <Activity className="h-5 w-5" />,
      image:
        'https://images.unsplash.com/photo-1576243345690-4e4b79b63288?q=80&w=2070&auto=format&fit=crop',
      color:
        'bg-emerald-50 text-emerald-600 dark:bg-emerald-950/20 dark:text-emerald-400',
      position: 'left',
      stats: [
        { value: '12', label: 'Activities' },
        { value: '30+', label: 'Metrics' },
        { value: 'GPS', label: 'Tracking' },
      ],
    },
    {
      id: 4,
      title: 'Smart Notifications',
      description:
        'Seamlessly receive and respond to messages, calls, and app notifications, with customizable quick replies and voice-to-text input for instant responses.',
      icon: <Smartphone className="h-5 w-5" />,
      image:
        'https://images.unsplash.com/photo-1551816230-ef5deaed4a26?q=80&w=2065&auto=format&fit=crop',
      color: 'bg-blue-50 text-blue-600 dark:bg-blue-950/20 dark:text-blue-400',
      position: 'right',
      stats: [
        { value: 'All', label: 'Apps' },
        { value: 'Quick', label: 'Replies' },
        { value: 'Voice', label: 'Input' },
      ],
    },
    {
      id: 5,
      title: '50m Water Resistance',
      description:
        'Fully waterproof design suitable for swimming, showering, and water sports. Automatically tracks swim metrics including laps, pace, and stroke type.',
      icon: <Droplet className="h-5 w-5" />,
      image:
        'https://images.unsplash.com/photo-1524805444758-089113d48a6d?q=80&w=2024&auto=format&fit=crop',
      color: 'bg-cyan-50 text-cyan-600 dark:bg-cyan-950/20 dark:text-cyan-400',
      position: 'left',
      stats: [
        { value: '50m', label: 'Depth' },
        { value: '5ATM', label: 'Rating' },
        { value: 'Swim', label: 'Tracking' },
      ],
    },
    {
      id: 6,
      title: 'Sleep Insights',
      description:
        'Advanced sleep stage tracking differentiates between light, deep, and REM sleep phases, providing detailed analysis and personalized recommendations for better rest.',
      icon: <Timer className="h-5 w-5" />,
      image:
        'https://images.unsplash.com/photo-1531353826977-0941b4779a1c?q=80&w=2070&auto=format&fit=crop',
      color:
        'bg-purple-50 text-purple-600 dark:bg-purple-950/20 dark:text-purple-400',
      position: 'right',
      stats: [
        { value: '3', label: 'Sleep Stages' },
        { value: 'Daily', label: 'Score' },
        { value: 'Smart', label: 'Alarm' },
      ],
    },
  ];

  return (
    <section className="bg-background w-full overflow-hidden py-12 md:py-24 lg:py-32">
      <div className="container mx-auto px-4 md:px-6 2xl:max-w-[1400px]">
        <div className="mb-12 flex flex-col items-center space-y-4 text-center md:mb-20">
          <Badge className="px-3.5 py-1.5">Smart Innovation</Badge>
          <h2 className="text-3xl font-bold tracking-tighter sm:text-4xl md:text-5xl">
            Your life at a glance
          </h2>
          <p className="text-muted-foreground max-w-[700px] md:text-xl/relaxed">
            Our smartwatch combines cutting-edge technology with elegant design
            to help you stay connected, healthy, and productive.
          </p>
        </div>

        {/* Main product image */}
        <div className="mb-20 flex justify-center">
          <div className="relative aspect-square w-full max-w-md overflow-hidden rounded-xl border shadow-lg">
            <img
              src="https://images.unsplash.com/photo-1617043786394-f977fa12eddf?q=80&w=1974&auto=format&fit=crop"
              alt="SmartWatch Pro X2"
              className="object-cover"
              sizes="(max-width: 768px) 100vw, 500px"
            />
            <div className="absolute inset-0 flex items-end bg-gradient-to-t from-black/60 to-transparent">
              <div className="p-6 text-white">
                <Badge variant="secondary" className="mb-2">
                  New Release
                </Badge>
                <h3 className="text-2xl font-semibold">SmartWatch Pro X2</h3>
                <p className="mt-1 text-white/80">Intelligence on your wrist</p>
              </div>
            </div>
          </div>
        </div>

        {/* Timeline features */}
        <div className="relative">
          {/* Timeline center line */}
          <div className="bg-border absolute top-0 bottom-0 left-1/2 hidden w-0.5 -translate-x-1/2 md:block" />

          {features.map((feature, index) => (
            <div
              key={feature.id}
              className={cn(
                'scroll-reveal relative mb-16 opacity-100 transition-all duration-700 md:mb-24',
                index % 2 === 0 ? 'md:ml-0' : 'md:mr-0'
              )}
            >
              {/* Timeline dot */}
              <div className="border-background bg-primary absolute left-1/2 z-10 hidden h-8 w-8 -translate-x-1/2 items-center justify-center rounded-full border-4 md:flex">
                <span className="text-primary-foreground text-xs font-bold">
                  {feature.id}
                </span>
              </div>

              <div
                className={cn(
                  'grid items-center gap-8 md:grid-cols-2',
                  feature.position === 'right' ? 'md:grid-flow-row-dense' : ''
                )}
              >
                {/* Feature image */}
                <div
                  className={cn(
                    'overflow-hidden rounded-xl border shadow',
                    feature.position === 'left'
                      ? 'md:col-start-1'
                      : 'md:col-start-2'
                  )}
                >
                  <div className="relative aspect-video">
                    <img
                      src={feature.image}
                      alt={feature.title}
                      className="object-cover"
                      sizes="(max-width: 768px) 100vw, 50vw"
                    />
                  </div>
                </div>

                {/* Feature content */}
                <div
                  className={cn(
                    'space-y-6',
                    feature.position === 'left'
                      ? 'md:col-start-2'
                      : 'md:col-start-1',
                    'flex flex-col justify-center'
                  )}
                >
                  <div className="flex items-center space-x-3">
                    <div
                      className={cn(
                        'flex h-10 w-10 shrink-0 items-center justify-center rounded-full',
                        feature.color
                      )}
                    >
                      {feature.icon}
                    </div>
                    <h3 className="text-xl font-bold">{feature.title}</h3>
                  </div>

                  <p className="text-muted-foreground">{feature.description}</p>

                  {/* Feature stats */}
                  <div className="flex space-x-6">
                    {feature.stats.map((stat, i) => (
                      <div key={i} className="text-center">
                        <div className="text-xl font-bold">{stat.value}</div>
                        <div className="text-muted-foreground text-xs tracking-wider uppercase">
                          {stat.label}
                        </div>
                      </div>
                    ))}
                  </div>

                  <Button
                    variant="outline"
                    size="sm"
                    className={cn(
                      'w-fit',
                      feature.position === 'right' ? 'md:self-end' : ''
                    )}
                  >
                    Learn more
                    <ArrowRight className="ml-2 h-4 w-4" />
                  </Button>
                </div>
              </div>
            </div>
          ))}
        </div>

        {/* CTA section */}
        <div className="mx-auto mt-24 max-w-2xl space-y-8 text-center">
          <div className="space-y-4">
            <h3 className="text-2xl font-bold">
              Ready to experience the future?
            </h3>
            <p className="text-muted-foreground">
              The SmartWatch Pro X2 comes with a 45-day satisfaction guarantee
              and 2-year warranty. Available in three elegant finishes: Midnight
              Black, Silver Frost, and Rose Gold.
            </p>
          </div>

          <div className="flex flex-wrap justify-center gap-4">
            <Button size="lg" asChild>
              <a href="#">
                Pre-order Now
                <ArrowRight className="ml-2 h-4 w-4" />
              </a>
            </Button>
            <Button size="lg" variant="outline" asChild>
              <a href="#">View Full Specifications</a>
            </Button>
          </div>

          <div className="pt-6">
            <div className="text-muted-foreground flex items-center justify-center gap-6">
              <div className="flex items-center">
                <Zap className="text-primary mr-2 h-5 w-5" />
                <span>Fast Charging</span>
              </div>
              <div className="flex items-center">
                <Droplet className="text-primary mr-2 h-5 w-5" />
                <span>Water Resistant</span>
              </div>
              <div className="flex items-center">
                <Heart className="text-primary mr-2 h-5 w-5" />
                <span>Health Tracking</span>
              </div>
            </div>
          </div>
        </div>
      </div>
    </section>
  );
}
```

### `components/ui/badge.tsx`

```tsx
import * as React from "react"
import { cva, type VariantProps } from "class-variance-authority"
import { Slot } from "radix-ui"

import { cn } from "@/lib/utils"

const badgeVariants = cva(
  "group/badge inline-flex h-5 w-fit shrink-0 items-center justify-center gap-1 overflow-hidden rounded-4xl border border-transparent px-2 py-0.5 text-xs font-medium whitespace-nowrap transition-all focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&>svg]:pointer-events-none [&>svg]:size-3!",
  {
    variants: {
      variant: {
        default: "bg-primary text-primary-foreground [a]:hover:bg-primary/80",
        secondary:
          "bg-secondary text-secondary-foreground [a]:hover:bg-secondary/80",
        destructive:
          "bg-destructive/10 text-destructive focus-visible:ring-destructive/20 dark:bg-destructive/20 dark:focus-visible:ring-destructive/40 [a]:hover:bg-destructive/20",
        outline:
          "border-border text-foreground [a]:hover:bg-muted [a]:hover:text-muted-foreground",
        ghost:
          "hover:bg-muted hover:text-muted-foreground dark:hover:bg-muted/50",
        link: "text-primary underline-offset-4 hover:underline",
      },
    },
    defaultVariants: {
      variant: "default",
    },
  }
)

function Badge({
  className,
  variant = "default",
  asChild = false,
  ...props
}: React.ComponentProps<"span"> &
  VariantProps<typeof badgeVariants> & { asChild?: boolean }) {
  const Comp = asChild ? Slot.Root : "span"

  return (
    <Comp
      data-slot="badge"
      data-variant={variant}
      className={cn(badgeVariants({ variant }), className)}
      {...props}
    />
  )
}

export { Badge, badgeVariants }
```

### `components/ui/button.tsx`

```tsx
import * as React from "react"
import { cva, type VariantProps } from "class-variance-authority"
import { Slot } from "radix-ui"

import { cn } from "@/lib/utils"

const buttonVariants = cva(
  "group/button inline-flex shrink-0 items-center justify-center rounded-md border border-transparent bg-clip-padding text-sm font-medium whitespace-nowrap transition-all outline-none select-none focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 active:not-aria-[haspopup]:translate-y-px disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
  {
    variants: {
      variant: {
        default: "bg-primary text-primary-foreground hover:bg-primary/80",
        outline:
          "border-border bg-background shadow-xs hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:border-input dark:bg-input/30 dark:hover:bg-input/50",
        secondary:
          "bg-secondary text-secondary-foreground hover:bg-secondary/80 aria-expanded:bg-secondary aria-expanded:text-secondary-foreground",
        ghost:
          "hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:hover:bg-muted/50",
        destructive:
          "bg-destructive/10 text-destructive hover:bg-destructive/20 focus-visible:border-destructive/40 focus-visible:ring-destructive/20 dark:bg-destructive/20 dark:hover:bg-destructive/30 dark:focus-visible:ring-destructive/40",
        link: "text-primary underline-offset-4 hover:underline",
      },
      size: {
        default:
          "h-9 gap-1.5 px-2.5 in-data-[slot=button-group]:rounded-md has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2",
        xs: "h-6 gap-1 rounded-[min(var(--radius-md),8px)] px-2 text-xs in-data-[slot=button-group]:rounded-md has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3",
        sm: "h-8 gap-1 rounded-[min(var(--radius-md),10px)] px-2.5 in-data-[slot=button-group]:rounded-md has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5",
        lg: "h-10 gap-1.5 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2",
        icon: "size-9",
        "icon-xs":
          "size-6 rounded-[min(var(--radius-md),8px)] in-data-[slot=button-group]:rounded-md [&_svg:not([class*='size-'])]:size-3",
        "icon-sm":
          "size-8 rounded-[min(var(--radius-md),10px)] in-data-[slot=button-group]:rounded-md",
        "icon-lg": "size-10",
      },
    },
    defaultVariants: {
      variant: "default",
      size: "default",
    },
  }
)

function Button({
  className,
  variant = "default",
  size = "default",
  asChild = false,
  ...props
}: React.ComponentProps<"button"> &
  VariantProps<typeof buttonVariants> & {
    asChild?: boolean
  }) {
  const Comp = asChild ? Slot.Root : "button"

  return (
    <Comp
      data-slot="button"
      data-variant={variant}
      data-size={size}
      className={cn(buttonVariants({ variant, size, className }))}
      {...props}
    />
  )
}

export { Button, buttonVariants }
```
