'use client';

import { createLazyComponent } from '../../components';
import type { PlayerProps } from './types';

export const LazyPlayer = createLazyComponent<PlayerProps>(
  () => import('./Player').then((mod) => ({ default: mod.Player })),
  {
    displayName: 'LazyAudioPlayer',
    fallback: (
      <div className="rounded-lg border border-border/60 bg-card px-4 py-6 text-sm text-muted-foreground">
        Loading audio player…
      </div>
    ),
  },
);
