
	/*toggle unbox*/
function toggle_active(ctl)
{
    ctl.parentElement.classList.toggle('is-active');
}

			/*toggle inflection*/
function toggle_infl() {
	var x = document.querySelector("vp-gs");
	style = window.getComputedStyle(x);
	display = style.getPropertyValue('display');

	if (x.style.display === "none"||display === "none") {
		x.style.display = "block";
	} else {
		x.style.display = "none";
	}
  
	var y = document.querySelector("pos[onclick]");
	if ( y.className.match(/(?:^|\s)Clicked(?!\S)/) )
	{y.className =y.className.replace( /(?:^|\s)Clicked(?!\S)/g , '' )}
	else{y.setAttribute("class", "Clicked");}
	
  
}

/////////////////////////////////////////////////////////////////////////////////////////
/*toggle image*/
function getElementByAttr(t, e, i) {
	for (var n = document.getElementsByTagName(t), d = [], r = 0; r < n.length; r++) n[r].getAttribute(e) == i && d.push(n[r]);
	return d
}

function expand_big(t) {
	var e = getElementByAttr("div", "idd", t.getAttribute("idd"));
	e[0].setAttribute("style", "display:none"), e[1].setAttribute("style", "display:block")
}

function expand_thumb(t) {
	var e = getElementByAttr("div", "idd", t.getAttribute("idd"));
	e[1].setAttribute("style", "display:none"), e[0].setAttribute("style", "display:block")
}


function toggle_active(ctl)
{
    ctl.parentElement.classList.toggle('is-active');
}

function toggle_enlarger(ctl)
{
    var fullsize = ctl.children[0].children[0],
        thumb = ctl.children[0].children[1],
        enlarge = ctl.children[0].children[2];

    if (fullsize.style.display == 'none') {
        fullsize.style.display = 'block';
        thumb.style.display = 'none';
        enlarge.style.display = 'none';
    } else {
        fullsize.style.display = 'none';
        thumb.style.display = 'block';
        enlarge.style.display = 'block';
    }
}
function switch_entry(ctl)
{
    if (event.target == ctl) {return;}
    var i;
    var x = document.getElementsByClassName('body');
    for (i = 0; i < x.length; i++) {
        x[i].style.display = 'none';
    }

    for (i = 0; i < ctl.children.length; i++) {
        if (ctl.children[i] == target) {
            continue;
        }
        ctl.children[i].style.backgroundColor = '';
    }
}
