$(document).ready(function($) {
const selector = $('#rasp');
function update() {
const value = selector.val();
const theIndex = parseInt(value) - 1;
$('.rasp-events').each(function(index, el) {
$(el)[index === theIndex ? 'show' : 'hide']();
});
};
selector.on('click', update);
update();
});
$(document).on('click', function(e) {console.log(e.target)});