"use client";

import { Eye } from "lucide-react";

type BlogHighlightPreviewProps = {
  source: string;
  isVideo: boolean;
  label: string;
};

export function BlogHighlightPreview({
  source,
  label,
}: BlogHighlightPreviewProps) {
  return (
    <a
      href={source}
      target="_blank"
      rel="noopener noreferrer"
      className="absolute right-3 top-3 z-10 inline-flex h-9 items-center justify-center rounded-full bg-white/95 px-3 text-sm font-black text-[var(--theme-primary)] shadow-sm transition hover:bg-white"
      aria-label={`Open ${label} in a new tab`}
    >
      <Eye className="mr-1.5 h-4 w-4" />
      View
    </a>
  );
}
