Diensten
Oplossingen
Branches
Regio
Plan een gesprek 085 369 7668 info@neddev.com

Videospeler met eigen bediening Nieuw

Een eigen videospeler rond het gewone video-element: afspelen, tijdlijn, tijd, geluid uit en volume, ondertiteling aan of uit en volledig scherm. De bediening verdwijnt tijdens afspelen na 2,5 seconden stilstand en komt terug bij muis of focus. Sneltoetsen: spatie of k, pijltjes (5 s), m, c en f. Ondertitels komen uit een tekstspoor (hier in de JS opgebouwd, in productie een .vtt-bestand). Voor bedrijfsfilms en productvideo's waar de standaardspeler niet bij de huisstijl past.

0:00 / 0:22

Zo gebruik je het

  1. Plak de HTML op de plek waar het onderdeel moet komen.
  2. Zet de CSS in je stylesheet. Alle klassen hebben een eigen voorvoegsel, dus niets botst met je eigen opmaak.
  3. Voeg de JavaScript toe en roep init() aan met het element waar de HTML in staat.
<!-- Videospeler met eigen bediening · © 2026 NedDev BV · NedDev Lab-licentie (gratis gebruik, niet doorverkopen) · neddev.com/nl/lab/gebruik/#licentie -->
<div class="jouw-container">
<div class="vsp" tabindex="-1">
<video class="vsp__v" preload="metadata" playsinline poster="https://neddev.com/lab-media/videospeler-eigen-1.webp" aria-label="Bedrijfsfilm Houtwerkplaats Van Dijk, 22 seconden"><source src="https://neddev.com/lab-media/videospeler-eigen-film.mp4" type="video/mp4"></video>
<p class="vsp__cc" hidden></p>
<button class="vsp__big" type="button" aria-label="Film afspelen"><svg viewBox="0 0 24 24" aria-hidden="true"><path d="M8 5.5v13l10.5-6.5z"/></svg></button>
<div class="vsp__bar">
<button class="vsp__b vsp__play" type="button" aria-label="Afspelen"><svg class="vsp__ic-play" viewBox="0 0 24 24" aria-hidden="true"><path d="M8 5.5v13l10.5-6.5z"/></svg><svg class="vsp__ic-pause" viewBox="0 0 24 24" aria-hidden="true"><path d="M7 5h3.5v14H7zM13.5 5H17v14h-3.5z"/></svg></button>
<input class="vsp__tl" type="range" min="0" max="22" step="0.1" value="0" aria-label="Tijdlijn" aria-valuetext="0:00 van 0:22">
<span class="vsp__t"><span class="vsp__cur">0:00</span> / <span class="vsp__dur">0:22</span></span>
<button class="vsp__b vsp__mute" type="button" aria-label="Geluid uit" aria-pressed="false"><svg viewBox="0 0 24 24" aria-hidden="true"><path d="M4 9.5h3.5L12 5.5v13l-4.5-4H4z"/><path class="vsp__wave" d="M15 9c1.3 1.6 1.3 4.4 0 6M17.5 6.8c2.6 2.9 2.6 7.5 0 10.4" fill="none" stroke="currentColor" stroke-width="1.8" stroke-linecap="round"/><path class="vsp__x" d="M15.5 9.5l5 5m0-5l-5 5" fill="none" stroke="currentColor" stroke-width="1.8" stroke-linecap="round"/></svg></button>
<input class="vsp__vol" type="range" min="0" max="1" step="0.05" value="0.8" aria-label="Volume">
<button class="vsp__b vsp__ccb" type="button" aria-label="Ondertiteling" aria-pressed="false"><svg viewBox="0 0 24 24" aria-hidden="true"><rect x="3" y="5.5" width="18" height="13" rx="2" fill="none" stroke="currentColor" stroke-width="1.8"/><path d="M10.5 10.3a2.2 2.2 0 1 0 0 3.4M17 10.3a2.2 2.2 0 1 0 0 3.4" fill="none" stroke="currentColor" stroke-width="1.6" stroke-linecap="round"/></svg></button>
<button class="vsp__b vsp__fs" type="button" aria-label="Volledig scherm"><svg viewBox="0 0 24 24" aria-hidden="true"><path d="M4 9V4h5M15 4h5v5M20 15v5h-5M9 20H4v-5" fill="none" stroke="currentColor" stroke-width="1.9"/></svg></button>
</div>
</div>
</div>

Meer uit componenten

Iets gezien dat je mooi vindt?

Zet het in je selectie en stuur hem op. Dan bouwen we je site eromheen, in jouw huisstijl.

Neem contact op →