Options

The Ravnur Media Player provides a set of options to customize the behavior and appearance of the player. Below is a list of available options, including default values and descriptions.


PropertyDefault ValueTypeDescription
aesTokenundefinedstringAES Token value. This property specifies the AES Token used for decryption.
loggerundefinedPlayerLoggerCustom logger implementation for the player.
loggerLevel2numberSets the severity level of logs (0-4: error, warn, info, debug, trace).
i18nnullPlayerTranslationCustom translations object for internationalization.
showPlaytruebooleanShows play/pause button in the player controls.
showProgresstruebooleanShows the progress bar and time indicators.
showVolumetrue (false on mobile)booleanShows volume control slider and mute button.
showFullScreentrue (false for audio)booleanShows fullscreen toggle button.
showTheaterModefalsebooleanShows theater mode button for wide screen viewing.
showClosedCaptionstruebooleanShows closed captions/subtitles toggle and menu.
showCaptionSearchfalsebooleanShows caption search functionality in the menu.
showTOCtrue (false for audio)booleanShows table of contents/chapters menu.
showAnnotationstrue (false for audio)booleanShows annotations overlay on the video.
showQualitytrue (false on mobile/audio)booleanShows quality level selector in settings.
showAudioTracksfalsebooleanShows audio track selector for multi-audio content.
showPostertruebooleanShows poster image before playback starts.
showPlaceholdertruebooleanAdds play button overlay on the poster/video.
showPlaybackRatetrue (false on Android)booleanShows playback speed control in settings.
showForwardtruebooleanShows skip forward button (default: 10 seconds).
showBackwardtruebooleanShows skip backward button (default: 10 seconds).
showSettingstruebooleanShows settings menu button.
showDownloadtruebooleanShows download button for media content. Depends on showDownloadVideo and showDownloadCC properties.
showDownloadVideotruebooleanShows video download option in the download menu. Requires downloadVideoURL property to be set.
showDownloadCCfalsebooleanShows closed captions download option in the download menu.
showTitletrue (false on mobile)booleanShows media title in the player.
showNextFramefalsebooleanShows next frame button for frame-by-frame navigation.
showPrevFramefalsebooleanShows previous frame button for frame-by-frame navigation.
showCCLayouttrue (false on mobile)booleanEnables caption layout customization in CC settings.
showPrevfalsebooleanShows previous track button in fullscreen mode.
showNextfalsebooleanShows next track button in fullscreen mode.
showBottomNextfalsebooleanShows next track button at the bottom of the player.
showBottomPrevfalsebooleanShows previous track button at the bottom of the player.
showCrawlfalsebooleanShows scrolling text crawl overlay.
crawlnullPlayerCrawlOptionsConfiguration object for crawl text (text, speed, colors).
downloadVideoURLnullstringSpecific URL for video download option.
downloadCCLanguagesnullArray<{code, label}>Array of available caption languages for download with language codes and labels.
isLivefalsebooleanEnables live-stream mode, jumping to live edge on start.
isProgressLiveStreamfalsebooleanDisables progress bar seeking and current time indicator for live streams.
showSubtitlesfalsebooleanDisables captions built into the manifest.
showErrorfalsebooleanShows default error message. Set to false to provide custom error handling.
isAudiofalse (auto-detected)booleanEnables audio-only mode with simplified UI.
timecode0numberSets the timecode offset value in seconds.
frameRate23.976numberSets the frame rate for frame-accurate navigation.
clipundefined[number, number]Plays a specific segment of media [startTime, endTime] in seconds.
autoStartfalsebooleanAutomatically starts playback when the player is ready.
startTimenullnumberSets the initial playback position in seconds.
endTimenullnumberSets the end time for playback in seconds.
useOriginTimeForPreviewtruebooleanUses original timeline for thumbnail previews.
accessibilityfalsebooleanEnables accessibility features for screen readers and keyboard navigation.
playlistmodeautoPlayerPlaylistModeControls playlist position: "auto", "right", "bottom", "hidden".
playlistAutoGoNexttruebooleanAutomatically plays next media item when current ends.
playlistitle""stringTitle displayed above the playlist.
playlistforcepoint0numberMinimum width (px) before forcing playlist to bottom position.
playLoopfalsebooleanAutomatically restarts playback from beginning when media ends.
hideplaylistfalsebooleanHides playlist item thumbnails and previews.
alwaysShowExtensionsfalsebooleanKeeps controls visible even during playback.
extensionsVisibilityTimeout2000 (4000 on mobile)numberTime in milliseconds before hiding controls during playback.
skipDelta10numberNumber of seconds for skip forward/backward buttons.
keyboardListeners{}{ [key]: function }Custom keyboard shortcuts mapping key codes to handler functions.
globalKeyboardListenersfalsebooleanWhen true, keyboard shortcuts work globally; when false, only in player area.
isHandlingKeyboardEventstruebooleanEnables or disables keyboard event handling.
bufferingTimeout200numberDelay in milliseconds before showing buffering spinner.
isMobileauto-detectedbooleanForces mobile mode UI. Auto-detected by default.
nextTrackThumbnailsnullstringThumbnail image URL for the next track in playlist.
nextTrackTitlenullstringTitle text for the next track in playlist.
prevTrackThumbnailsnullstringThumbnail image URL for the previous track in playlist.
prevTrackTitlenullstringTitle text for the previous track in playlist.
hlsjsURLCDN lateststringURL to specific hls.js library version.
shakaURLCDN lateststringURL to specific Shaka Player library version.
flashPath"/"stringPath to Flash fallback SWF files.
hlsSee defaultsHls.js optionsHLS.js configuration object for HTTP Live Streaming playback settings.
shakaSee defaultsShaka Player optionsShaka Player configuration object for DASH and advanced streaming features.
savePlayTimefalsebooleanSaves last playback position to localStorage for resume functionality.
widevineURLundefinedstringWidevine DRM license server URL. See example below.
playreadyURLundefinedstringPlayReady DRM license server URL. See example below.
fairplayURLundefinedstringFairPlay DRM license server URL. See example below.
fairplayCertificateUrlundefinedstringFairPlay DRM certificate URL for authentication.
playbackRates[0.5, 0.8, 1, 1.5, 2, 3, 5]number[]Custom playback speed options. Value 1 always present as "Standard". Range: 0.01-5.
qualityLevel"Auto"stringInitial video quality (e.g., "720", "1080"). "Auto" adjusts based on connection speed.
startLevel"Auto"stringInitial HLS quality level index. Similar to qualityLevel but uses level index instead of resolution.
maxQualityLevelundefinednumberMaximum quality level index allowed. Useful for limiting bandwidth usage.
disableAutoFullScreenOnIOSfalsebooleanPrevents automatic fullscreen mode on iOS devices during video playback.
disableAutoUrlRewritefalsebooleanDisables automatic URL rewriting for media sources.
useHTMLPlayerfalsebooleanForces the use of native HTML5 video player instead of advanced players.
useHLSJSPlayerfalsebooleanForces the use of HLS.js player for HLS streams instead of native playback.

Advanced Configuration Objects

HLS Configuration

Ravnur Player has set of default options for hls.js configuration. You can override them by passing your own options to the player. For full list of options, see hls.js API documentation.

// Default HLS.js configuration
{
  maxFragLookUpTolerance: 0.5,
  maxMaxBufferLength: 600,
  highBufferWatchdogPeriod: 3,
  playlistLoadPolicy: {
    default: {
      maxTimeToFirstByteMs: 10000,
      maxLoadTimeMs: 120000,
      timeoutRetry: {
        maxNumRetry: 10,
        retryDelayMs: 0,
        maxRetryDelayMs: 0
      },
      errorRetry: {
        maxNumRetry: 10,
        retryDelayMs: 3000,
        maxRetryDelayMs: 8000
      }
    }
  }
}

Shaka Configuration

We do not set any default options for Shaka Player. You can set them by passing your own options to the player. Refer to the Shaka Player documentation for available options.

Internationalization (i18n)

The player supports custom translations through the i18n option. Below is a list of all available translation keys and their usage.

KeyDefault ValueUsage
fullscreenFullscreenFullscreen button tooltip
exit-fullscreenExit full screenExit fullscreen button tooltip
theaterTheater modeTheater mode button tooltip
exit-theaterStandard modeExit theater mode button tooltip
playPlayPlay button tooltip
pausePausePause button tooltip
replayReplayReplay button tooltip when video ends
standard-playbackrateStandardStandard playback rate label (1x)
forwardForward 10 secSkip forward button tooltip
backwardBack 10 secSkip backward button tooltip