Skip to main content
speak-mintlify automatically injects an audio player component into your MDX files. This component displays the TTS audio with a custom player interface.

Default Component

By default, speak-mintlify uses the AudioTranscript component:
speaker-config.yaml
This component is injected at the top of each MDX file:

Component Structure

The audio component receives a voices prop with the following structure:

Default Component Features

The included AudioTranscript component provides:
  • Play/pause button with smooth transitions
  • Progress bar with seeking
  • Time display (current/total)
  • Voice selector dropdown (when multiple voices configured)
  • Dark mode support
  • Responsive design
  • Fish Audio S1 branding

Component Implementation

Here’s the full default component implementation:
audio-transcript.jsx

Customizing the Component

You can create your own custom audio player component:
1

Create your component

Create a custom React component in your Mintlify snippets folder:
snippets/custom-player.jsx
2

Update speaker-config.yaml

Configure speak-mintlify to use your custom component:
speaker-config.yaml
3

Regenerate audio

Run the generate command to update your MDX files:

Component Requirements

Your custom component must:
  1. Accept a voices prop (array of { name: string, url: string })
  2. Be a named export (not default export)
  3. Be compatible with Mintlify’s React environment
  4. Handle the case where voices is empty or undefined
Your component must work with Mintlify’s MDX rendering. Avoid using incompatible React features or browser-only APIs during SSR.

Styling

The default component uses Tailwind CSS classes compatible with Mintlify’s theme. For custom styling:
  • Use Tailwind classes for consistency with Mintlify’s design
  • Support both light and dark mode with dark: variants
  • Use Mintlify’s CSS variables for colors (e.g., bg-card, text-muted-foreground)

CLI Overrides

You can override component settings via CLI:

Next Steps

Speaker Config

Configure voices and settings

.speakignore

Exclude files from processing