<commit_before><div class="container">
<div class="main-menu">

	<% years = Conference.uniq.pluck(:year).sort %>
	<% years = years[0...-1] %>
	<% active_year = @conference.year %>


	<ul class="conference-menu" id='conference_menu' years='<%= years %>' active='<%= yield :active_conference %>'>

		<% years.each do |year| %>

			<% if year === active_year %>
				<% flag_settings = {conf_display: ''} %>
			<% else %>
				<% flag_settings = {conf_display: "display:none;"} %>
			<% end %>

			<li class="flag-year-image-container" id="flag-<%=year%>" year='<%=year%>'>
				<%= image_tag('RED.png')%>
				<p class='flag-text'> <%= year %> </p> 
			</li>

			<% Conference.where(year: year).order(date: :asc).each do |conference| %>

				<% if conference === @conference %>
					<% flag_settings[:flag_color] = 'BLUE.png' %>
				<% else %>
					<% flag_settings[:flag_color] = 'GREY.png' %>
				<% end %>

				<li class="flag-image-container conference-<%= year %> conference-flag" style="<%=flag_settings[:conf_display]%>" >
					<%= link_to(  image_tag(flag_settings[:flag_color]), about_conference_path(conference.fullname) )%>
					<div class='flag-text'> <%= link_to  conference.name + " " + conference.year.to_s, about_conference_path(conference.fullname) %> </div>  

				</li>

			<% end %>

		<% end %>

		<% current_year = years[-1].to_i + 1 %>

		<% Conference.where(year: current_year).each do |conference| %>
			<li class="flag-image-container conference-<%= current_year %> conference-flag" >
				<%= link_to(  image_tag('GREEN.png'), about_conference_path(conference.fullname) )%>
				<div class='flag-text'> <%= link_to  conference.name + " " + conference.year.to_s, about_conference_path(conference.fullname) %> </div> 
			</li>
		<% end %>

</ul>
</div>



<script>
// $(document).ready(function () {

// 	$('li.conference-menu').hover(function(){
// 	    $(this).addClass('hovered');
// 	},function(){
// 	    $(this).removeClass('hovered');
// 	});

// 	$( ".redBtn" ).click(function() {
// 		$(this).parent().find( ".old-other" ).first().toggle( 100, function showNext() {
// 			$( this ).next( ".old-other" ).toggle( 100, showNext );
// 		});
// 	});
// 	$( ".blueBtn" ).click(function() {
// 		$( ".year-other" ).first().toggle( 100, function showNext() {
// 			$( this ).next( ".year-other" ).toggle( 100, showNext );
// 		});
// 	});
// 	$( ".blueBtn2").click(function() {
// 		$( ".future-other" ).first().toggle( 100, function showNext() {
// 			$( this ).next( ".future-other" ).toggle( 100, showNext );
// 		});
// 	});
// });
</script><commit_msg>change color of year flag<commit_after><div class="container">
<div class="main-menu">

	<% years = Conference.uniq.pluck(:year).sort %>
	<% years = years[0...-1] %>
	<% active_year = @conference.year %>


	<ul class="conference-menu" id='conference_menu' years='<%= years %>' active='<%= yield :active_conference %>'>

		<% years.each do |year| %>

			<% if year === active_year %>
				<% flag_settings = {conf_display: '', year_flag_color: 'RED.png'} %>
			<% else %>
				<% flag_settings = {conf_display: "display:none;", year_flag_color: 'GREY.png'} %>
			<% end %>

			<li class="flag-year-image-container" id="flag-<%=year%>" year='<%=year%>'>
				<%= image_tag(flag_settings[:year_flag_color])%>
				<p class='flag-text'> <%= year %> </p> 
			</li>

			<% Conference.where(year: year).order(date: :asc).each do |conference| %>

				<% if conference === @conference %>
					<% flag_settings[:conf_flag_color] = 'BLUE.png' %>
				<% else %>
					<% flag_settings[:conf_flag_color] = 'GREY.png' %>
				<% end %>

				<li class="flag-image-container conference-<%= year %> conference-flag" style="<%=flag_settings[:conf_display]%>" >
					<%= link_to(  image_tag(flag_settings[:conf_flag_color]), about_conference_path(conference.fullname) )%>
					<div class='flag-text'> <%= link_to  conference.name + " " + conference.year.to_s, about_conference_path(conference.fullname) %> </div>  

				</li>

			<% end %>

		<% end %>

		<% current_year = years[-1].to_i + 1 %>

		<% Conference.where(year: current_year).each do |conference| %>
			<li class="flag-image-container conference-<%= current_year %> conference-flag" >
				<%= link_to(  image_tag('GREEN.png'), about_conference_path(conference.fullname) )%>
				<div class='flag-text'> <%= link_to  conference.name + " " + conference.year.to_s, about_conference_path(conference.fullname) %> </div> 
			</li>
		<% end %>

</ul>
</div>



<script>
// $(document).ready(function () {

// 	$('li.conference-menu').hover(function(){
// 	    $(this).addClass('hovered');
// 	},function(){
// 	    $(this).removeClass('hovered');
// 	});

// 	$( ".redBtn" ).click(function() {
// 		$(this).parent().find( ".old-other" ).first().toggle( 100, function showNext() {
// 			$( this ).next( ".old-other" ).toggle( 100, showNext );
// 		});
// 	});
// 	$( ".blueBtn" ).click(function() {
// 		$( ".year-other" ).first().toggle( 100, function showNext() {
// 			$( this ).next( ".year-other" ).toggle( 100, showNext );
// 		});
// 	});
// 	$( ".blueBtn2").click(function() {
// 		$( ".future-other" ).first().toggle( 100, function showNext() {
// 			$( this ).next( ".future-other" ).toggle( 100, showNext );
// 		});
// 	});
// });
</script>
{'fraction_non_alphanumeric': 0.24277016742770166, 'fraction_numerical': 0.008751902587519025, 'mean_word_length': 3.4778534923339013, 'pattern_counts': {'":': 0, '<': 107, '<?xml version=': 0, '>': 107, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3206291', 'n_tokens_mistral': 2217, 'n_tokens_neox': 1859, 'n_words': 299}