"use client";

import nextDynamic from "next/dynamic";
import type { RoutePoint } from "@/lib/models/running";

const RouteMap = nextDynamic(() => import("@/components/route-map").then((m) => m.RouteMap), {
  ssr: false,
  loading: () => <div className="h-full w-full animate-pulse rounded-2xl bg-surface" />,
});

export function RouteMapSection({ points }: { points: RoutePoint[] }) {
  return <RouteMap points={points} />;
}
