Sha256: e67fbb9b72a39c78291f3077ae43d1237bb9ade3d7478217aaa37826e8829398

Contents?: true

Size: 558 Bytes

Versions: 8

Compression:

Stored size: 558 Bytes

Contents

/**
 * nav.js
 * JavaScript functions for the main navigation menu (used on small screens)
 * and for the modal box.
 */


function openNavMenu() {
  document.querySelectorAll('header nav')[0].style.width = 'auto';
}

function closeNavMenu() {
  document.querySelectorAll('header nav')[0].style.width = '0';
}

function openModal() {
  document.getElementById('modal').style.display = 'block';
}

window.onclick = function(event) {
  if (event.target == document.getElementById('modal')) {
    document.getElementById('modal').style.display = 'none';
  }
}

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
intranet-core-2.1.1 lib/intranet/resources/www/nav.js
intranet-core-2.1.0 lib/intranet/resources/www/nav.js
intranet-core-2.0.0 lib/intranet/resources/www/nav.js
intranet-core-1.2.0 lib/intranet/resources/www/nav.js
intranet-core-1.1.1 lib/intranet/resources/www/nav.js
intranet-core-1.0.2 lib/intranet/resources/www/nav.js
intranet-core-1.0.1 lib/intranet/resources/www/nav.js
intranet-core-1.0.0 lib/intranet/resources/www/nav.js