1(function( $ ) { 2 3 $(document).ready(function () { 4 5 // Close sample configs tip 6 $(".close-tip .fa-times").click(function(event) { 7 $(".sample-configs-tip").addClass("closed-config-tip"); 8 setTimeout(function() { 9 $(".open-sample-config-tip").addClass("show"); 10 }, 1000); 11 12 Cookies.set('software_sample_config_closed_tooltip', true, { expires: 360, path: '/' }); 13 14 event.preventDefault(); 15 }); 16 17 var software_sample_config_closed_tooltip = Cookies.get('software_sample_config_closed_tooltip'); 18 if(software_sample_config_closed_tooltip === 'true') 19 { 20 $(".sample-configs-tip").addClass("closed-config-tip"); 21 $(".open-sample-config-tip").addClass("show"); 22 } 23 24 // Open sample configs tip 25 $(".open-sample-config-tip").click(function(event) { 26 $(".sample-configs-tip").removeClass("closed-config-tip"); 27 $(this).removeClass('show'); 28 event.preventDefault(); 29 }); 30 31 // Show/Hide Additional Sample Configurations Details 32 $(".more-about-config").click(function(event) { 33 $(".more-sample-config").toggleClass("show"); 34 $(this).text(function(i, text){ 35 return text === ss.i18n._t('Software.LESS_DETAIL_CONFIG','Less details about this configuration') + ' [-]' ? 36 ss.i18n._t('Software.MORE_ABOUT_CONFIG', 'More about this configuration') + ' [+]' : 37 ss.i18n._t('Software.LESS_DETAIL_CONFIG', 'Less details about this configuration') + ' [-]'; 38 }) 39 event.preventDefault(); 40 }); 41 42 $('#sample_configurations_wrapper ul.sample-configs-subnav li a').click(function(event) { 43 $(this).position({ 44 left: "50%" 45 }); 46 event.preventDefault(); 47 }); 48 49 // Scroll Sample Configuration subnav with arrows 50 51 $('#config-right').click(function(event) { 52 event.preventDefault(); 53 $('.sample-configs-slider').animate({ 54 scrollLeft: "+=300px" 55 }, "fast"); 56 event.preventDefault(); 57 }); 58 $('#config-left').click(function(event) { 59 event.preventDefault(); 60 $('.sample-configs-slider').animate({ 61 scrollLeft: "-=300px" 62 }, "fast"); 63 event.preventDefault(); 64 }); 65 66 // Overview page, show/hide core projects 67 $('#choose-compute').click(function(event) { 68 $('#show-storage').addClass('grey'); 69 $('#show-compute').removeClass('grey'); 70 $('#compute-description').show(); 71 $('#storage-description').hide(); 72 $('#both-description').hide(); 73 event.preventDefault(); 74 }); 75 $('#choose-storage').click(function(event) { 76 $('#show-compute').addClass('grey'); 77 $('#show-storage').removeClass('grey'); 78 $('#compute-description').hide(); 79 $('#storage-description').show(); 80 $('#both-description').hide(); 81 event.preventDefault(); 82 }); 83 $('#choose-both').click(function(event) { 84 $('#show-storage').removeClass('grey'); 85 $('#show-compute').removeClass('grey'); 86 $('#compute-description').hide(); 87 $('#storage-description').hide(); 88 $('#both-description').show(); 89 event.preventDefault(); 90 }); 91 92 // Popovers 93 $('[data-toggle="popover"]').popover(); 94 95 // Tooltips 96 if(!('ontouchstart' in window)) { 97 $('[data-toggle="tooltip"]').tooltip(); 98 } 99 100 // Toggle All Projects Filters 101 $('#toggle-all-projects-filters').click(function(event) { 102 $('#all-projects-filter-wrapper').toggleClass('opened'); 103 $(this).toggleClass('active'); 104 event.preventDefault(); 105 }); 106 107 108 // Show/Hide Additional Sample Configurations Details 109 $(document).on('click', ".more-about-config", function(event) { 110 $(".more-sample-config").toggleClass("show"); 111 $(this).text(function(i, text){ 112 return text === ss.i18n._t('Software.LESS_DETAIL_CONFIG','Less details about this configuration') + ' [-]' ? 113 ss.i18n._t('Software.MORE_ABOUT_CONFIG', 'More about this configuration') + ' [+]' : 114 ss.i18n._t('Software.LESS_DETAIL_CONFIG', 'Less details about this configuration') + ' [-]'; 115 116 }) 117 event.preventDefault(); 118 return false;
119 }); 120 121 $(document).on('click','#sample_configurations_wrapper ul.sample-configs-subnav li a', function(event) { 122 $(this).position({ 123 left: "50%" 124 }); 125 event.preventDefault(); 126 return false; 127 }); 128 // Scroll Sample Configuration subnav with arrows 129 130 $('#config-right').click(function(event) { 131 132 $('.sample-configs-slider').animate({ 133 scrollLeft: "+=300px" 134 }, "fast"); 135 event.preventDefault(); 136 return false; 137 }); 138 139 $('#config-left').click(function(event) { 140 $('.sample-configs-slider').animate({ 141 scrollLeft: "-=300px" 142 }, "fast"); 143 event.preventDefault(); 144 return false; 145 }); 146 147 // prevent submiting form on enter key press 148 $('#all-projects-search').keydown(function(event){ 149 if(event.keyCode == 13) { 150 event.preventDefault(); 151 return false; 152 } 153 }); 154 155 }); 156 157 // End of closure. 158}( jQuery ));
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.