'use client';

import { useState } from 'react';

const prescriptionHistoryData = [
  {
    patient: 'John Doe',
    medicine: 'Aspirin',
    date: '2025-04-20',
  },
  {
    patient: 'Jane Smith',
    medicine: 'Paracetamol',
    date: '2025-04-18',
  },
  {
    patient: 'George Martin',
    medicine: 'Ibuprofen',
    date: '2025-04-15',
  },
];

export default function PrescriptionHistorySection() {
  return (
    <div className="bg-white shadow rounded-lg p-6 space-y-4">
      <h2 className="text-xl font-semibold">Prescription History</h2>
      {prescriptionHistoryData.map((item, index) => (
        <div
          key={index}
          className="border-b pb-3 last:border-b-0 text-sm text-gray-700"
        >
          <p><strong>Patient:</strong> {item.patient}</p>
          <p><strong>Medicine:</strong> {item.medicine}</p>
          <p><strong>Date:</strong> {item.date}</p>
        </div>
      ))}
    </div>
  );
}
