forked from toolshed/coopcloud.tech
		
	make case studies expandable
This commit is contained in:
		
							
								
								
									
										10
									
								
								static/js/expandable.js
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										10
									
								
								static/js/expandable.js
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,10 @@
 | 
			
		||||
document.getElementById( 'case_studies-slide-more' ).addEventListener( 'click', function() {
 | 
			
		||||
  var body = document.getElementById( 'case_studies-slide-body' );
 | 
			
		||||
  if( body.className == 'expanded' ) {
 | 
			
		||||
      body.className = 'contracted';
 | 
			
		||||
      document.getElementById( 'case_studies-slide-more' ).textContent = 'Expand';
 | 
			
		||||
  } else {
 | 
			
		||||
      body.className = 'expanded';
 | 
			
		||||
      document.getElementById( 'case_studies-slide-more' ).textContent = 'Compress';
 | 
			
		||||
  };
 | 
			
		||||
} );
 | 
			
		||||
		Reference in New Issue
	
	Block a user