diff options
| author | adamhrv <adam@ahprojects.com> | 2019-02-28 18:50:22 +0100 |
|---|---|---|
| committer | adamhrv <adam@ahprojects.com> | 2019-02-28 18:50:22 +0100 |
| commit | 6c631c88c9ecc2683b95534cfd15e82650c1b501 (patch) | |
| tree | 786d993a57c8c4d6fba26cad5fbda056c346c418 /client/splash | |
| parent | 9e3bb35630349847bc005389c408f3072e0e22db (diff) | |
| parent | e845766d970f4afefc2fc47367c3478413f98ff2 (diff) | |
Merge branch 'master' of github.com:adamhrv/megapixels_dev
Diffstat (limited to 'client/splash')
| -rw-r--r-- | client/splash/index.js | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/client/splash/index.js b/client/splash/index.js index e247b7f5..a21110f0 100644 --- a/client/splash/index.js +++ b/client/splash/index.js @@ -31,12 +31,14 @@ function build() { function bind() { document.querySelector('.slogan').addEventListener('click', modal.close) - toArray(document.querySelectorAll('.aboutLink')).forEach(el => { - el.addEventListener('click', modal.toggle) - }) - document.querySelector('.about .inner').addEventListener('click', e => e.stopPropagation()) - document.querySelector('.about').addEventListener('click', modal.close) - document.querySelector('.close').addEventListener('click', modal.close) + if (document.querySelector('.about')) { + toArray(document.querySelectorAll('.aboutLink')).forEach(el => { + el.addEventListener('click', modal.toggle) + }) + document.querySelector('.about .inner').addEventListener('click', e => e.stopPropagation()) + document.querySelector('.about').addEventListener('click', modal.close) + document.querySelector('.close').addEventListener('click', modal.close) + } } function animate() { |
