$(function(){var a=$("#searchmenu");var d=$(".expand1");var c=$(".expand2");d.each(function(){$(this).attr("initialDisplay",$(this).css("display"))});c.each(function(){$(this).attr("initialDisplay",$(this).css("display"))});function b(n,g,f){var m="is-excluded";var l="delexp1";var j=toZenkakuKana(n.val().toLowerCase());var e=j.replace(/　/g," ").split(" ");if(n.val()===""){f.each(function(){$(this).css({display:$(this).attr("initialDisplay")})});$("."+m).removeClass(m);$("."+l).addClass("expand1");$("."+l).removeClass(l).show();g.each(function(){$(this).css({display:$(this).attr("initialDisplay")})})}else{$(".expand2").show();$(".expand1").addClass(l);$(".expand1").removeClass("expand1");$("."+m).removeClass(m).show();f.each(function(){for(i=0;i<e.length;i++){var o=toZenkakuKana($(this).text().toLowerCase());if(o.indexOf(e[i])<=0){$(this).addClass(m)}}});var k=0;g.each(function(){var r=false;var q=$(this).attr("id");if(q!==undefined&&q!==""){while(k<f.length){var p=f.eq(k).attr("id");var o=f.eq(k).attr("class");if($(this).children("a").length===1){r=true}if(p.indexOf(q)<0){break}if(o.indexOf(m)<0){r=true}k++}if(r===false){$(this).addClass(m)}}});var h=$("."+l);h.each(function(){var o=$(this).attr("id");if(o===undefined||o===""){var p=$(this).find("."+l).not(".is-excluded");if(p.length===0){$(this).addClass(m)}}});$("."+m).hide()}}a.bind("input propertychange",function(){b(a,d,c)})});