Nathan's Web Components
A bunch of web components for my own convenience.
Audio Player
A handy audio player widget.
Attributes:
- audio: a URI pointing to an audio file
- cover: a URI pointing to a cover image
- cover_alt: alt text for the cover image
Slots:
- title: title for the audio file
- description: a description of the audio file
CSS Custom Properties:
- --background
Example usage:
<audio-player
cover="/assets/images/doge.jpg"
cover_alt="A snoozy doge!"
audio="assets/audio/KARATE KID - TOXIC (ILLFD022).wav">
<h3 slot="title">Toxic - Britney Spears (Karate Kid Bootleg)</h3>
<p slot="description">A massive DnB roller bootleg of a Britney Spears classic: <em>Toxic</em>.</p>
</audio-player>
Toxic - Britney Spears (Karate Kid Bootleg)
A massive DnB roller bootleg of a Britney Spears classic: Toxic.