cancel
Showing results for 
Search instead for 
Did you mean: 

JUMP TO PIVOT CELL COLOR FORMAT

cartercjb
10 - ETL
10 - ETL

I have the following code that formats the pivot table seen below: 

widget.on("ready",function(w, args) {
	var headerBgColor = '#a90a40'; //Header background
	var headerFontColor = '#F2F3F2'; //Header Font Color
	var footBgColor = '#44546A'; // Pivot Foot (Totals)
	var footFontColor = '#F2F3F2'; // Pivot Column (dims)
	var colFontColor = '#5690a2';
		// Style
		var $jx = $(".p-dim-head,.p-dim-member-head,.p-measure-head", element);
			$jx.css('font-size' , '12px');
			$jx.css('font-weight' , 'bold');
			$jx.css('color' , headerFontColor);
			$jx.css('background-color' , headerBgColor);
			$jx.css('text-align' , 'center'); 
			$jx.css('vertical-align' , 'middle'); 
		// GRAND TOTAL
		var $jx = $(".p-grand-total-head,.p-grand-total-row-head,.p-grand-total-val", element);
			$jx.css('font-size' , '12px');
			$jx.css('font-weight' , 'bold');
			$jx.css('color' , headerFontColor);
			$jx.css('background-color' , headerBgColor);
			$jx.css('text-align' , 'left'); 
			$jx.css('vertical-align' , 'middle');
		//center values and col	
			$(".p-value", element).css('text-align', 'center');
			$(".p-dim-head", element).css('text-align', 'left');
		// row totals	
		var $jx= $(".p-total-row-val,.p-total-row-head", element);
			$jx.css('font-size' , '12px');
			$jx.css('font-weight' , 'bold');
			$jx.css('color' , footFontColor);
			$jx.css('background-color' , footBgColor);
			$jx.css('border-top', 'none');		
		// col
		var $jx = $(".p-dim-member", element);
			$jx.css('font-size' , '10px');
			$jx.css('font-weight' , 'bold');
			$jx.css('color' , colFontColor);
			$jx.css('text-align' , 'left'); 		
	    var $jx = $(".p-value", element);
			$jx.css('font-size' , '10px');			
		// boarders
		var $jx = $("[fidx]", element);
			$jx.css('border-bottom', 'thin solid ' + colFontColor);
			$jx.css('border-right', 'thin solid ' + colFontColor);
}) 


Is there a way to update the script to target the font color of all the values (which are blue)? All of these values are blue because the Jump to dashboard feature is enabled.

cartercjb_0-1653074419912.png

 

0 REPLIES 0