1
0
mirror of https://github.com/bigchaindb/site.git synced 2024-11-02 00:05:37 +01:00
site/_src/_assets/javascripts/page-about.js
2017-08-22 23:35:36 +02:00

19 lines
643 B
JavaScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

document.addEventListener('DOMContentLoaded', function() {
var trigger = document.getElementsByClassName('team__bio__trigger')[0]
var bio = document.getElementsByClassName('team__bio')
trigger.addEventListener('click', function(e) {
for (var i = 0; i < bio.length; ++i) {
var item = bio[i]
if (item.style.display == 'block') {
item.style.display = 'none'
trigger.innerHTML = '<span>+</span>Show bios'
} else {
item.style.display = 'block'
trigger.innerHTML = '<span></span>Hide bios'
}
}
})
})