2017-02-10 19:23:01 +00:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
								function fix_opts_func(defaults/*:Array<Array<any> >*/)/*:{(o:any):void}*/ {
							 | 
						
					
						
							
								
									
										
										
										
											2014-06-29 18:29:45 +00:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
									return function fix_opts(opts) {
							 | 
						
					
						
							| 
								
							 | 
							
								
							 | 
							
								
							 | 
							
							
										for(var i = 0; i != defaults.length; ++i) {
							 | 
						
					
						
							| 
								
							 | 
							
								
							 | 
							
								
							 | 
							
							
											var d = defaults[i];
							 | 
						
					
						
							
								
									
										
										
										
											2014-07-28 13:22:32 +00:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
											if(opts[d[0]] === undefined) opts[d[0]] = d[1];
							 | 
						
					
						
							
								
									
										
										
										
											2014-05-16 00:33:34 +00:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
											if(d[2] === 'n') opts[d[0]] = Number(opts[d[0]]);
							 | 
						
					
						
							
								
									
										
										
										
											2014-06-29 18:29:45 +00:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
										}
							 | 
						
					
						
							
								
									
										
										
										
											2014-05-16 00:33:34 +00:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
									};
							 | 
						
					
						
							
								
									
										
										
										
											2014-02-07 10:53:40 +00:00
										 
									 
								 
							 | 
							
								
							 | 
							
								
							 | 
							
							
								}
							 | 
						
					
						
							
								
									
										
										
										
											2014-05-16 00:33:34 +00:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
								
							 | 
						
					
						
							
								
									
										
										
										
											2022-03-14 06:51:33 +00:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
								function fix_read_opts(opts) {
							 | 
						
					
						
							
								
									
										
										
										
											2020-09-11 08:38:33 +00:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
								fix_opts_func([
							 | 
						
					
						
							
								
									
										
										
										
											2014-05-16 00:33:34 +00:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
									['cellNF', false], /* emit cell number format string as .z */
							 | 
						
					
						
							| 
								
							 | 
							
								
							 | 
							
								
							 | 
							
							
									['cellHTML', true], /* emit html string as .h */
							 | 
						
					
						
							| 
								
							 | 
							
								
							 | 
							
								
							 | 
							
							
									['cellFormula', true], /* emit formulae as .f */
							 | 
						
					
						
							
								
									
										
										
										
											2014-05-29 06:18:23 +00:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
									['cellStyles', false], /* emits style/theme as .s */
							 | 
						
					
						
							
								
									
										
										
										
											2017-04-21 22:02:02 +00:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
									['cellText', true], /* emit formatted text as .w */
							 | 
						
					
						
							
								
									
										
										
										
											2014-10-26 05:26:18 +00:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
									['cellDates', false], /* emit date cells with type `d` */
							 | 
						
					
						
							
								
									
										
										
										
											2014-05-16 00:33:34 +00:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
								
							 | 
						
					
						
							| 
								
							 | 
							
								
							 | 
							
								
							 | 
							
							
									['sheetStubs', false], /* emit empty cells */
							 | 
						
					
						
							| 
								
							 | 
							
								
							 | 
							
								
							 | 
							
							
									['sheetRows', 0, 'n'], /* read n rows (0 = read all rows) */
							 | 
						
					
						
							| 
								
							 | 
							
								
							 | 
							
								
							 | 
							
							
								
							 | 
						
					
						
							| 
								
							 | 
							
								
							 | 
							
								
							 | 
							
							
									['bookDeps', false], /* parse calculation chains */
							 | 
						
					
						
							| 
								
							 | 
							
								
							 | 
							
								
							 | 
							
							
									['bookSheets', false], /* only try to get sheet names (no Sheets) */
							 | 
						
					
						
							| 
								
							 | 
							
								
							 | 
							
								
							 | 
							
							
									['bookProps', false], /* only try to get properties (no Sheets) */
							 | 
						
					
						
							
								
									
										
										
										
											2015-04-02 20:32:22 +00:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
									['bookFiles', false], /* include raw file structure (keys, files, cfb) */
							 | 
						
					
						
							
								
									
										
										
										
											2014-05-16 00:33:34 +00:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
									['bookVBA', false], /* include vba raw data (vbaraw) */
							 | 
						
					
						
							| 
								
							 | 
							
								
							 | 
							
								
							 | 
							
							
								
							 | 
						
					
						
							
								
									
										
										
										
											2015-04-02 20:32:22 +00:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
									['password',''], /* password */
							 | 
						
					
						
							
								
									
										
										
										
											2014-05-16 00:33:34 +00:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
									['WTF', false] /* WTF mode (throws errors) */
							 | 
						
					
						
							
								
									
										
										
										
											2020-09-11 08:38:33 +00:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
								])(opts);
							 | 
						
					
						
							
								
									
										
										
										
											2022-03-14 06:51:33 +00:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
								}
							 | 
						
					
						
							
								
									
										
										
										
											2014-05-16 00:33:34 +00:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
								
							 | 
						
					
						
							
								
									
										
										
										
											2022-03-14 06:51:33 +00:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
								function fix_write_opts(opts) {
							 | 
						
					
						
							| 
								
							 | 
							
								
							 | 
							
								
							 | 
							
							
								fix_opts_func([
							 | 
						
					
						
							
								
									
										
										
										
											2014-10-26 05:26:18 +00:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
									['cellDates', false], /* write date cells with type `d` */
							 | 
						
					
						
							| 
								
							 | 
							
								
							 | 
							
								
							 | 
							
							
								
							 | 
						
					
						
							
								
									
										
										
										
											2014-05-16 00:33:34 +00:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
									['bookSST', false], /* Generate Shared String Table */
							 | 
						
					
						
							| 
								
							 | 
							
								
							 | 
							
								
							 | 
							
							
								
							 | 
						
					
						
							| 
								
							 | 
							
								
							 | 
							
								
							 | 
							
							
									['bookType', 'xlsx'], /* Type of workbook (xlsx/m/b) */
							 | 
						
					
						
							| 
								
							 | 
							
								
							 | 
							
								
							 | 
							
							
								
							 | 
						
					
						
							
								
									
										
										
										
											2017-02-03 20:50:45 +00:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
									['compression', false], /* Use file compression */
							 | 
						
					
						
							| 
								
							 | 
							
								
							 | 
							
								
							 | 
							
							
								
							 | 
						
					
						
							
								
									
										
										
										
											2014-05-16 00:33:34 +00:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
									['WTF', false] /* WTF mode (throws errors) */
							 | 
						
					
						
							
								
									
										
										
										
											2022-03-14 06:51:33 +00:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
								])(opts);
							 | 
						
					
						
							| 
								
							 | 
							
								
							 | 
							
								
							 | 
							
							
								}
							 |