Services
Solutions
Industries
Regions
Book a call 085 369 7668 info@neddev.com

Dag/nacht-schakelaar

A light and dark switch: the sun slides across and turns into a moon, clouds sink away and stars appear. The surrounding area changes with it. Accessible as role="switch".

Nachtweergave

Het is dag

How to use it

  1. Paste the HTML where the forms & inputs should appear.
  2. Add the CSS to your stylesheet. All classes are prefixed, so nothing clashes with your own styles.
  3. Add the JavaScript and call init() with the element that contains the HTML.
<!-- Dag/nacht-schakelaar · © 2026 NedDev BV · NedDev Lab-licentie (gratis gebruik, niet doorverkopen) · neddev.com/nl/lab/gebruik/#licentie -->
<div class="jouw-container">
<div class="h3dn">
  <div class="h3dn-rij">
    <span class="h3dn-lab">Nachtweergave</span>
    <button class="h3dn-sw" type="button" role="switch" aria-checked="false" aria-label="Nachtweergave">
      <span class="h3dn-lucht" aria-hidden="true">
        <i class="h3dn-ster"></i><i class="h3dn-ster"></i><i class="h3dn-ster"></i><i class="h3dn-ster"></i><i class="h3dn-ster"></i>
        <i class="h3dn-wolk"></i><i class="h3dn-wolk"></i>
      </span>
      <span class="h3dn-bol" aria-hidden="true"><i class="h3dn-krater"></i><i class="h3dn-krater"></i><i class="h3dn-krater"></i></span>
    </button>
  </div>
  <p class="h3dn-stand" aria-live="polite">Het is dag</p>
</div>
</div>

More forms & inputs

Seen something you like?

Add it to your selection and send it over. We build your site around it, in your brand.

Get in touch →