Skip to content

VAudioPlayer

Props

NameTypeDescription
connotationEnum:
accent
cta
Sets the color of the audio player
current-timenumber
disabledbooleanSets the disabled state of the audio player
durationnumber
duration-fallbackbooleanEnables fallback logic to fetch and decode audio buffer for duration when metadata is missing.
notimebooleanHides the time stamp
pause-button-aria-labelstring
pausedboolean
play-button-aria-labelstring
playback-ratenumber
playback-ratesstringComma-separated string of numbers to define playback speeds
skip-backward-aria-labelstring
skip-byEnum:
0
5
10
30
Allows the audio to skip back or forward
skip-forward-aria-labelstring
slider-aria-labelstring
srcstringSets the audio source URL

Events

NameEvent TypeDescription
blurFocusEventFires when the element loses focus.
clickMouseEventFires when a pointing device button (such as a mouse's primary mouse button) is both pressed and released while the pointer is located inside the element.
focusFocusEventFires when the element receives focus.
inputEventFires when the value of an element has been changed.
keydownKeyboardEventFires when a key is pressed.
keyupKeyboardEventFires when a key is released.
pauseCustomEvent<undefined>Fires when the audio playback is paused.
playCustomEvent<undefined>Fires when the audio playback is started.

Methods

NameTypeDescription
pause() => void
play() => void